| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
[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, and additional
documentation. No review.
|
|
|
|
|
|
|
|
| |
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 assessing the "runtime type"
of an object. No review.
|
|
|
|
|
|
|
|
|
| |
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.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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 better.
|
| |
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
| |
|
| |
|
|
|
|
|
| |
2nd attempt to survive divergent implicits in the presentation compiler.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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 functionality. Code continues to
fall away like so many dry leaves. No review.
|
|
|
|
|
|
| |
Remove the currentRun after a build, inside the build manager. review by
plocinic.
|
|
|
|
|
|
| |
Cleared 'createdSyntheticMethod' on resetTyper (another leak in the
presentation compiler). review by extempore.
|
|
|
|
|
|
| |
Minor fix for Choice setting plus added some deprecated methods that
should survive till next release. review by extempore
|
|
|
|
|
| |
Reverted divergent implicits change which caused build failures.
|
|
|
|
|
|
| |
Reverts r24155, which light testing says is the culprit for recent
failures. Review by odersky.
|
|
|
|
|
|
| |
Eliminating duplication and trying to outrun obsolescence in the
exciting world of fsc. No review.
|
|
|
|
|
|
|
|
|
| |
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 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 typecompletion for IDE.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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-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.
|
|
|
|
|
|
| |
I mistakenly used a synchronous call when creating the server. No
review.
|
|
|
|
|
|
| |
handlers plus general cruft reduction. It's a comprehensibility party in
there. No review.
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
| |
Cut off the hunt for completions once something raises its hand so we
don't end up with java.lang.Double members in scala.Double. Closes
#3955, no review.
|
|
|
|
|
|
| |
from an object to a lazy val so it can be overridden in subclasses.
Closes #3513, no review.
|
|
|
|
|
|
| |
Boy, I try not to let any String.isEmpty get by but I'm not as vigilant
as ol' java5. No review.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
from that point forward will be run as atPhase(phase) { <line> }.
Reasonably flexible syntax:
scala> :phase erasure.next
Active phase is now: Lazyvals (erasure.next)
scala> :phase typer+3
Active phase is now: Refchecks (typer+3)
scala> :phase clear
Cleared active phase.
No review.
|
|
|
|
|
|
|
| |
interfaces from implementations and isolating jline better so it doesn't
become an accidental dependency or have other unexpected effects. No
review.
|
|
|
|
|
|
| |
Fixed bug in IndexedSeqOptimized.indexWhere such that the empty string
would find things all over the place. Closes #4197, no review.
|
|
|
|
|
|
|
|
|
|
|
|
| |
up the stray interpreter files and put them in the interpreter package.
Would really love to change the name of that package. Went looking for
some consistent divisions of responsibility and consistent naming.
Made some progress. There are deprecated versions of most everything I
changed so hopefully the carnage will be limited.
This isn't completely baked but I just realized I broke the build
earlier and this should fix it. I'll keep the oven on. No review.
|
|
|
|
|
|
| |
Fixed some generic signature bugs I found thanks to the compiler telling
me it was buggy. Thanks compiler. No review.
|
| |
|
| |
|
|
|
|
|
|
| |
onUnitOf moved to CompilerControl and made public, so free for public
use now.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
interpreter and the interpreter loop has become so fuzzy it can hardly
be said to exist. In this commit I take a step or two toward clearer
boundaries, and also fix some gratuitous name inconsistencies with the
rest of trunk. A Global should be called "global" in the absence of a
compelling reason otherwise.
Also, now having had a couple years to explore every inch of the design
space, I can announce that where possible to use them, distinguished
objects like NoType and NoSymbol are far superior to swaddling things
in Option. Applied this piece of canon to Completion and History. No
review.
|
|
|
|
|
|
| |
A raw tree was making its way into an error message. Removed. Closes
#4196, no review.
|
|
|
|
|
|
| |
Made the presentation compiler reporter in interactive tests show up
error messages.no review.
|
|
|
|
|
|
|
|
| |
Changing some code to not use collect on top of a possibly changing
filesystem. Anonymous partial functions used with collect risk match
errors if guard results ever change, due to the guard being run twice
(isDefinedAt and then apply). No review.
|
|
|
|
|
|
| |
Primarily a cleanup of the organization of keywords for the scala and
java parsers, and a few other Name-related items. No review.
|
|
|
|
|
| |
trying to fix CyclicReference errors for type completion
|