summaryrefslogtreecommitdiff
path: root/src/reflect
Commit message (Collapse)AuthorAgeFilesLines
* Statistics improvements and bug fixes.Martin Odersky2012-06-254-69/+138
| | | | Added compile-time option hotEnabled to Statistics that can be used to count very high frequency methods with 0 overhead for the disabled case. Fixed problem with weak maps that caused some timers to be discarded prematurely before they could be printed. Fixed problem with accouning for stacked timers.
* adds `narrow` to the reflection APIEugene Burmako2012-06-191-2/+10
| | | | as per https://issues.scala-lang.org/browse/SI-5951
* Merge pull request #746 from adriaanm/pullreq/740-rebasedAdriaan Moors2012-06-196-172/+312
|\ | | | | Statistics reorganization
| * Statistics reorganizationMartin Odersky2012-06-196-172/+312
| | | | | | | | | | Statistics were broken since the move to reflect.internal. They are now re-organized, made more robost and modular.
* | Merge pull request #729 from scalamacros/topic/showrawAdriaan Moors2012-06-198-115/+286
|\ \ | |/ |/| improve showRaw
| * improves showRawEugene Burmako2012-06-198-115/+286
| | | | | | | | addresses concerns raised in http://groups.google.com/group/scala-user/browse_thread/thread/de5a5be2e083cf8e
* | Merge pull request #728 from scalamacros/topic/reflection-meetingJosh Suereth2012-06-181-0/+17
|\ \ | | | | | | exposes extra tests for symbols as discussed on reflection meeting
| * | exposes extra tests for symbols as discussed on reflection meetingEugene Burmako2012-06-151-0/+17
| | | | | | | | | | | | review by @odersky
* | | fixes checkinit, now it's for realEugene Burmako2012-06-182-9/+1
|/ /
* | Fix for broken forwarder.Paul Phillips2012-06-141-1/+1
| | | | | | | | | | | | | | Wow, I wonder what the upper bound is on how long I might have chased my tail before finding this. I know what the lower bound is, unfortunately. It's just that usually the answer to a mystery is not "the empty package class has magically become the root class, but only sometimes."
* | fixes a checkinit problemEugene Burmako2012-06-131-0/+2
|/
* Avoids cyclic reference error in AddInterfaces.Martin Odersky2012-06-081-1/+2
| | | | | | Compile Global or Typers twice in resident mode yielded a CyclicReference error, in phase erasure. The error was due to a cyclic call of isDerivedValue class. Checking I noted that isDerivedValue class is called very often, and mostly unneccessesarily. I tightened teh condition to not force the type of the class if it is a trait or package. This made the CyclicReference go away. Widened criterion that enables validation of derived value classes. Previous version made two neg tests slip through.
* Reduce time spent in lubsMartin Odersky2012-06-085-78/+110
| | | | | | | | | | Reduce time spent in lubs by making depth more adaptive. It now takes into account separately the depth of the lub types and the maximal depth of theior base type sequences. It cuts depth more aggressively if it is the base types instead of the types themselves that grow deep. The old truncation behavior is retained under option -Xfull-lubs Another change is that we now track depth more precisely, which should also help or at least allow better statistics. Also added statistics that measure #lubs and time spent in them.
* tests and fixes for the mirror APIEugene Burmako2012-06-083-75/+99
|
* de-duplicate isUncheckedAnnotation/isSwitchAnnotationAdriaan Moors2012-06-081-0/+6
|
* fixes some issues with reflectField brought up todayEugene Burmako2012-06-081-7/+34
|
* TypeTag => AbsTypeTag, ConcreteTypeTag => TypeTagEugene Burmako2012-06-087-42/+41
| | | | | This protects everyone from the confusion caused by stuff like this: https://issues.scala-lang.org/browse/SI-5884
* removes array tagsEugene Burmako2012-06-082-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before 2.10 we had a notion of ClassManifest that could be used to retain erasures of abstract types (type parameters, abstract type members) for being used at runtime. With the advent of ClassManifest (and its subtype Manifest) it became possible to write: def mkGenericArray[T: Manifest] = Array[T]() When compiling array instantiation, scalac would use a ClassManifest implicit parameter from scope (in this case, provided by a context bound) to remember Ts that have been passed to invoke mkGenericArray and use that information to instantiate arrays at runtime (via Java reflection). When redesigning manifests into what is now known as type tags, we decided to explore a notion of ArrayTags that would stand for abstract and pure array creators. Sure, ClassManifests were perfectly fine for this job, but they did too much - technically speaking, one doesn't necessarily need a java.lang.Class to create an array. Depending on a platform, e.g. within JavaScript runtime, one would want to use a different mechanism. As tempting as this idea was, it has also proven to be problematic. First, it created an extra abstraction inside the compiler. Along with class tags and type tags, we had a third flavor of tags - array tags. This has threaded the additional complexity though implicits and typers. Second, consequently, when redesigning tags multiple times over the course of Scala 2.10.0 development, we had to carry this extra abstraction with us, which exacerbated the overall feeling towards array tags. Finally, array tags didn't fit into the naming scheme we had for tags. Both class tags and type tags sound logical, because, they are descriptors for the things they are supposed to tag, according to their names. However array tags are the odd ones, because they don't actually tag any arrays. As funny as it might sound, the naming problem was the last straw that made us do away with the array tags. Hence this commit.
* backward compatibility bridgesEugene Burmako2012-06-082-0/+21
| | | | | More information can be found here: https://groups.google.com/group/scala-internals/msg/138efc5476751269
* Introduces scala-reflect.jarEugene Burmako2012-06-08120-0/+30111