summaryrefslogtreecommitdiff
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Fixed a history bug with it not starting at the...Paul Phillips2011-02-071-1/+2
| | | | | Fixed a history bug with it not starting at the right index. No review.
* Added all the javap command line options to :ja...Paul Phillips2011-02-073-70/+115
| | | | | Added all the javap command line options to :javap. No review.
* The comment for isCoDefinedWith has long saidPaul Phillips2011-02-071-12/+15
| | | | | | | | | | | Is this symbol defined in the same scope and compilation unit as `that' symbol? But "same scope" was never checked, only "same compilation unit." Presumably other layers of logic kept this from being noticed until now, but it has been crashing sbt. Added check to isCoDefinedWith. Closes #4220, review by odersky.
* Fix for parser regression allowing 0-case match...Paul Phillips2011-02-071-2/+6
| | | | | | Fix for parser regression allowing 0-case match blocks. Closes #4217, no review.
* A bit more work on the symbol trackers.Paul Phillips2011-02-063-31/+76
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | minor inaccuracy, and added flag change tracking as well. Now the left column zone may show any of: * // new symbol F // flags changed O // owner changed Or sometimes the awe-inspiring "FO" as in this example. class A { def foo(unit: String) { def bar(x: String) = x == null } } [[symbol layout at end of lambdalift]] class A#17 constructor A#8017 FO method bar$1#9953 [Owner was method foo#8018, now class A#17] [+private +final +<local>] value x#9954 method foo#8018 value unit#9882 value <local A>#8019 No review.
* Added new option -Yshow-syms.Paul Phillips2011-02-063-1/+151
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | symbols. Specifically, it extracts all the symbols attached to AST nodes, and then prints them hierarchically along with indicators for new symbols and other interesting factoids like disappearing symbols. A small demonstration. Output shown is obviously only a fraction of what is produced. // a.scala class A { Nil foreach println } % scalac -Yshow-syms -uniqid a.scala [[symbol layout at end of selectivecps]] class A#17 constructor A#8019 value <local A>#8020 value $anonfun#10961 <synthetic> value x#10971 <synthetic> [[symbol layout at end of uncurry]] class A#17 constructor A#8019 value <local A>#8020 * anonymous class $anonfun#10993 final <synthetic> * constructor $anonfun#11001 * method apply#10994 final value x#10971 <synthetic> * value <local $anonfun>#10999 No review.
* [scaladoc] "Hide All" should be hide inherited ...Kato Kazuyoshi2011-02-061-0/+1
| | | | | | | [scaladoc] "Hide All" should be hide inherited members, not own. This issue is reported at http://lampsvn.epfl.ch/trac/scala/ticket/3775. review by dubochet.
* Fixed failure to load presentation compiler wit...Martin Odersky2011-02-051-1/+1
| | | | | | Fixed failure to load presentation compiler with sources in the empty package.
* [scaladoc] More faster index filtering.Kato Kazuyoshi2011-02-052-109/+159
|
* [scaladoc] More fixes for broken build. No review.Gilles Dubochet2011-02-041-9/+7
|
* [scaladoc] Scaladoc no longer crashes upon real...Gilles Dubochet2011-02-042-15/+21
| | | | | | [scaladoc] Scaladoc no longer crashes upon realising there is nothing to document. Closes #3928. No review.
* Added logging for compileLate, trying to figure...Iulian Dragos2011-02-041-0/+2
| | | | | | Added logging for compileLate, trying to figure out strange build problems in the IDE. no review.
* [scaladoc] Fixes the way new lines in wiki synt...Gilles Dubochet2011-02-041-3/+3
| | | | | | [scaladoc] Fixes the way new lines in wiki syntax convert to spaces. Closes #3735. No review.
* Added assertion to better diagnose build failures.Martin Odersky2011-02-041-1/+3
|
* [scaladoc] Strings looking like documentation a...Gilles Dubochet2011-02-041-12/+13
| | | | | [scaladoc] Strings looking like documentation attributes ("@something") inside "<pre>" blocks are not treated as attributes (like "{{{" blocks already did). Fixes #4212. No review.
* Presentation compiler yields now to be nicer to...Martin Odersky2011-02-041-0/+12
| | | | | Presentation compiler yields now to be nicer to UI thread.
* [scaladoc] Extends CSS of standard HTML generat...Gilles Dubochet2011-02-041-0/+4
| | | | | | [scaladoc] Extends CSS of standard HTML generator to display emphasied text in italic. Fixes #4185. No review.
* [scaladoc] Scaladoc recognises HTML entities in...Gilles Dubochet2011-02-041-1/+1
| | | | | | | [scaladoc] Scaladoc recognises HTML entities in comments, and leaves them untouched (except in code blocks defined using wiki syntax). Fixes #4184. No review.
* [scaladoc] Tweaks to `Generator` data structure...Gilles Dubochet2011-02-042-9/+15
| | | | | | [scaladoc] Tweaks to `Generator` data structure, and additional documentation. No review.
* After discovering #3376 was fixed I gave in and...Paul Phillips2011-02-041-1/+21
| | | | | | | | After discovering #3376 was fixed I gave in and tried to write a test. Now that the fiddling is over you can write repl tests without creating 5000 streams and settings. Look at test/files/run/bug3376.scala or jvm/interpreter.scala to see. Test case closes #3376, no review.
* Ignore anonymous and synthetic classes when ass...Paul Phillips2011-02-044-33/+48
| | | | | | Ignore anonymous and synthetic classes when assessing the "runtime type" of an object. No review.
* My repl history hasn't been working right for a...Paul Phillips2011-02-0416-89/+277
| | | | | | | | | My repl history hasn't been working right for a while (since about when jline2 was introduced.) Nobody else has said anything so either it's just me or I'm the only one using trunk, but either way I decided I'd rather write some history code than tinker with jline. So this is code to implement the jline history interface. No review.
* Faster interrupts in IDE when parsing.Martin Odersky2011-02-041-0/+1
|
* A couple long-threatened repl features.Paul Phillips2011-02-0311-296/+409
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1) :implicits command. scala> :implicits No implicits have been imported other than those in Predef. scala> import BigDecimal._ import BigDecimal._ scala> class Bippy[T] { implicit def makeMeABippy[U <: T] : Bippy[U] = new Bippy[U] } defined class Bippy scala> val bippy = new Bippy[String] bippy: Bippy[String] = Bippy@4f0bd71c scala> import bippy._ import bippy._ scala> :implicits /* 3 implicit members imported from scala.math.BigDecimal */ /* 3 defined in scala.math.BigDecimal */ implicit def double2bigDecimal(d: Double): scala.math.BigDecimal implicit def int2bigDecimal(i: Int): scala.math.BigDecimal implicit def long2bigDecimal(l: Long): scala.math.BigDecimal /* 1 implicit members imported from Bippy */ /* 1 defined in Bippy */ implicit def makeMeABippy[U <: T]: Bippy[U] 2) This one I will probably have to optionize, but: automatic rebinding to a more specific type, signalled via tab-completion failures. More easily demonstrated than explained. scala> val x: AnyRef = "abc" // does not apply to var/def x: AnyRef = abc scala> x.<tab> asInstanceOf isInstanceOf toString scala> x.<tab> Rebinding stable value x from AnyRef to java.lang.String + asInstanceOf charAt codePointAt codePointBefore codePointCount compareTo compareToIgnoreCase concat contains contentEquals endsWith equalsIgnoreCase getBytes getChars indexOf intern isEmpty isInstanceOf lastIndexOf length matches offsetByCodePoints regionMatches replace replaceAll replaceFirst split startsWith subSequence substring toCharArray toLowerCase toString toUpperCase trim scala> x res0: java.lang.String = abc Who's up for some reviewing? I'm taking volunteers! No review.
* Added an assertion to diagnose a build problem ...Martin Odersky2011-02-032-1/+2
| | | | | Added an assertion to diagnose a build problem better.
* invokeDynamic -> applyDynamicMartin Odersky2011-02-033-3/+3
|
* Switched back to StoreReporter for presentation...Iulian Dragos2011-02-031-2/+2
| | | | | | | | Switched back to StoreReporter for presentation compiler tests. This eats up error messages, but if the output is correct we don't mind a spurious error here and there. Renabled simple presentation compiler tests. no review.
* Enclosing method attributes.Paul Phillips2011-02-032-9/+20
| | | | | | | | | | | | | | have no constructor by the time genjvm rolls around, so NoSymbol emerges. Maybe the author of these two lines was under the impression that isClass == true implies isTrait == false, which it does not. assert(enclClass.isClass) val sym = enclClass.primaryConstructor 2) for reasons unknown the 0-arg constructor was hardcoded as the enclosing constructor, which is the wrong signature in all cases but that one. Closes #4211, review by dragos.
* changed buildStructure to askEnteredTypedMartin Odersky2011-02-024-55/+29
|
* Fixing a spaceleak in the IDE.Martin Odersky2011-02-021-6/+8
|
* 2nd attempt to survive divergent implicits in t...Martin Odersky2011-02-022-12/+12
| | | | | 2nd attempt to survive divergent implicits in the presentation compiler.
* What's in a name? 2 redundant fields, it seems.Iulian Dragos2011-02-021-3/+3
|
* Added javap to the repl.Paul Phillips2011-02-028-113/+280
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | so those hypothetical people who use non-sun jvms won't be thrown off kilter. You can give it a file argument or a class name, including classes you just defined in the repl, and it will clean up the repl mangling on the way out. scala> class Bippy { def hackenkraks(x: Float, y: Double) = 5 } defined class Bippy scala> :javap Bippy Compiled from "<console>" public class Bippy extends java.lang.Object implements scala.ScalaObject [...] public int hackenkraks(float, double); Signature: (FD)I Code: Stack=1, Locals=4, Args_size=3 0: iconst_5 1: ireturn scala> :javap scala.collection.Map public interface scala.collection.Map extends scala.collection.Iterable,scala.collection.MapLike,scala.ScalaObject [...] const #7 = Asciz ScalaSig; const #8 = Asciz <A:Ljava/lang/Object;B:Ljava/lang/Object;>Ljava/lang/Object;Lscala/collection/Iterable<Lscala/Tuple2<TA;TB;>;>;Lscala/collection/MapLike<TA;TB;Lscala/collection/Map<TA;TB;>;>;Lscala/ScalaObject;; const #9 = Asciz Lscala/reflect/ScalaSignature;; const #10 = Asciz bytes; const #11 = Asciz [line elided for control chars: possibly a scala signature] scala> :javap java.util.Enumeration Compiled from "Enumeration.java" public interface java.util.Enumeration [...] scala> :javap /scala/trunk/build/quick/classes/compiler/scala/tools/util/Javap.class Compiled from "Javap.scala" public class scala.tools.util.Javap extends java.lang.Object implements scala.ScalaObject [...] No review.
* Recent changes shattered :power mode functional...Paul Phillips2011-02-021-61/+50
| | | | | | Recent changes shattered :power mode functionality. Code continues to fall away like so many dry leaves. No review.
* Remove the currentRun after a build, inside the...Iulian Dragos2011-02-012-0/+10
| | | | | | Remove the currentRun after a build, inside the build manager. review by plocinic.
* Cleared 'createdSyntheticMethod' on resetTyper ...Iulian Dragos2011-02-012-0/+9
| | | | | | Cleared 'createdSyntheticMethod' on resetTyper (another leak in the presentation compiler). review by extempore.
* Minor fix for Choice setting plus added some de...Hubert Plociniczak2011-02-013-1/+9
| | | | | | Minor fix for Choice setting plus added some deprecated methods that should survive till next release. review by extempore
* Reverted divergent implicits change which cause...Martin Odersky2011-02-011-2/+2
| | | | | Reverted divergent implicits change which caused build failures.
* Reverts r24155, which light testing says is the...Paul Phillips2011-02-011-2/+2
| | | | | | Reverts r24155, which light testing says is the culprit for recent failures. Review by odersky.
* Eliminating duplication and trying to outrun ob...Paul Phillips2011-02-018-125/+118
| | | | | | Eliminating duplication and trying to outrun obsolescence in the exciting world of fsc. No review.
* I keep seeing huge simplifications available in...Paul Phillips2011-02-014-90/+125
| | | | | | | | | I keep seeing huge simplifications available in the repl. Lot of interesting features have come to town since it was first conceived. In this commit I give the internal names some tips on aesthetics, and put each line in its own package like civilized artificial constructs. No review.
* I found more situations where primitive types w...Paul Phillips2011-02-011-31/+31
| | | | | | | | I found more situations where primitive types were appearing in signatures. I hacked in a flag which says boxing is or is not allowed. The code is getting hideous: foortunately I have it mostly rewritten, but I wanted to fix this bug now. No review.
* Avoids divergent implicit crash in typecompleti...Martin Odersky2011-01-311-2/+2
| | | | | Avoids divergent implicit crash in typecompletion for IDE.
* Part2 of fix askStructure hangs commit.Martin Odersky2011-01-311-3/+8
|
* Fixed askStructure hangs.Martin Odersky2011-01-311-0/+7
|
* More work on the repl.Paul Phillips2011-01-315-63/+59
| | | | | | | | | | | | | | | | | the target, so it will no longer offer you methods that scala won't let you call. class B { def f = 5 ; def g = "a" } class C extends B { def BIPPY = List(1, 2, 3) } scala> val x: B = new C ; x.<tab> f g scala> val x: C = new C ; x.<tab> BIPPY f g No review.
* Undid some damage I did recently to tab-complet...Paul Phillips2011-01-319-122/+121
| | | | | | | | Undid some damage I did recently to tab-completion, and then made a bunch of stuff work better while I was at it. Clearly past time for some tests because I can't move a gear anywhere without unleashing an army of monkeys bearing wrenches. No review.
* Closes #4204, an issue with fsc.Paul Phillips2011-01-301-2/+2
| | | | | | I mistakenly used a synchronous call when creating the server. No review.
* More demonolithizing of the repl.Paul Phillips2011-01-306-348/+389
| | | | | | handlers plus general cruft reduction. It's a comprehensibility party in there. No review.
* Added a :keybindings command to the repl which ...Paul Phillips2011-01-305-10/+64
| | | | | | | | Added a :keybindings command to the repl which shows what each ctrl- key does. Thanks to mark harrah for the patch even though I wrote it afresh. Would be interested to know if it outputs anything remotely sensible on platforms which aren't OSX. Closes #3245, no review.