Commit Graph

10906 Commits

Author SHA1 Message Date
phaller fb8922192d Reverting unwanted parts of last commit.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19295 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-26 21:07:22 +00:00
phaller 809b8f4f16 Second half of fix and tests for #1518.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19293 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-26 21:01:12 +00:00
extempore f083dc39d8 Modifications to the five accumulated ant-parasite files which are
slowly driving me mad by being recompiled on every single run.
One file renamed, one moved to the right directory, two given
dummy implementations since they're completely commented out, and
the actors package object changed to apply to scala.actors
rather than _root_.actors.

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19292 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-26 20:56:32 +00:00
extempore 5f9f906158 The arrival of scala.Zero. This adds nothing to the
existing codebase.  What is it good for then? It's good
for nothing.  Thank you, I'll be here all night.

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19291 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-26 20:56:14 +00:00
phaller c421c018aa First half of fix for #1518.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19290 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-26 17:21:52 +00:00
extempore 005180cbed Fix for #2528.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19289 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-26 17:08:23 +00:00
extempore f7747cca30 Fix for #2529.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19288 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-26 17:00:19 +00:00
rytz d6ef73c9a2 new classpaths. cleaned up scopes. removed scope kinds. cleaned up symbol loading, integrated msil types, fix separate compilation for msil. Symbol.sourceFile only set for classes which are being compiled.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19285 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-26 09:56:33 +00:00
extempore 1b2fcb0c1e Attempting to unbreak fsc (can't reproduce the problem so can't
be entirely sure.)

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19278 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-25 19:00:29 +00:00
milessabin d147ee8db9 Suppression of a possible NPE which is almost certainly a side-effect of an earlier error. This change is better than the status quo, but clearly there's work to be done here.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19275 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-25 17:19:16 +00:00
milessabin c360154267 Export scala.tools.nsc.transform so that various useful things (eg. OverridingPairs) are accessible.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19274 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-25 17:16:09 +00:00
milessabin 0e9e3a8368 Add positions to AnnotationInfo for use by IDEs and other tools.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19273 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-25 17:12:45 +00:00
phaller fd3e9a33d6 Fix and test for #2515.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19267 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-25 08:31:33 +00:00
extempore fed2a7e582 Deprecation patrol. Just imagine, someday we'll be able to
compile scalac with -deprecation and not cause any machines
to catch fire.  Most of the remaining warnings are glancing
furtively at Tuple2, waiting for the moment to pounce.

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19266 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-25 06:00:59 +00:00
extempore e6fe4973c5 Fix and test case for #2512, plus lots of time expended
tuning HashSet starting sizes and growth rate, with almost
nothing to show for it (but I did determine that "shadowed"
is constructed identically something like 10,000 times, so
there is probably a cache to be had there.)

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19265 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-25 03:56:13 +00:00
dragos 058d63c0b3 Fixed isCoDefinedWith by undoing previous changes. It still looks broken, but this fixes the nightly until a better fix is devised
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19261 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-24 17:01:34 +00:00
extempore b1115f24bd Added scalac.args.quickonly to build.xml, because otherwise the
only way to fully test new command line options either involves
rebuilding starr every time or manually editing build.xml between
locker and quick.

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19257 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-23 18:56:42 +00:00
extempore 99a502e5bd Reorg of number parsing to use more direct logic.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19256 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-23 18:54:42 +00:00
extempore bc12d5e794 Parser fix involving backquoted identifiers (#2514) plus test case.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19253 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-23 15:37:20 +00:00
odersky bd07a3f459 fixed #2428 for good. Have BitSet's printthemselves as "BitSet(....)".
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19251 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-23 11:06:50 +00:00
extempore 873bdf3ddb The last patch to work around #1909 caught one brand of lifts
but not another.  Better now and another test case.

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19249 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 21:59:37 +00:00
extempore fb6fb492c5 Made sortBy unexperimental. Renamed Ordering's "map" to "on".
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19248 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 21:58:29 +00:00
extempore 7770fad82b Tickets #1909 and #2508 involve code which compiles but then
fails at runtime due to invalid bytecode.  This commit turns those
into compile time errors.  Includes negative test case.

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19247 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 21:09:57 +00:00
moors 5d8cf657ec new starr that does type constructor inference
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19246 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 17:04:32 +00:00
moors d56def331f the essence of tcpoly inference + test cases
fixes to check files and removed nonapplicable test case
Tuple2 impl, but commented out so that we can bootstrap
whitespace...

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19245 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 17:04:20 +00:00
extempore a785301e72 Added (a variation on) jorge ortiz's sortBy to SeqLike,
added docs and test case.  Added map to Ordering.

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19244 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 16:26:47 +00:00
dragos 919d2986aa Specialized works with Unit and handles correctly uncheckedVariance annotations.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19243 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 16:14:39 +00:00
extempore 82cf481b4f A pending test for #2087, and a script test which
is supposed to exercise r19165, except that I discovered that
no script tests have been run since July 2008: r15658 says "remove
script tests for now - they seem to block in certain configurations."

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19237 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 14:18:15 +00:00
moors 49023e4580 fixed breakage caused by r19219 -- sorry!
(thanks for alerting me, Toni)

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19230 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 12:07:56 +00:00
moors 331177879c Revert "added CanBuild type alias in package object scala.collection.generic" because it broke scaladoc (I consider that a bug -- filing ticket)
This reverts commit 5b3ba1c27cdce76d8aef2bfb9aa5a836237521a9.

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19229 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 11:58:42 +00:00
malayeri aafbe68aba Removed erroneous return type comment in scaladoc for remove(Int, Int)
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19223 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 10:43:02 +00:00
moors 7a5dfc3c9e removed some of the code duplication that Martin pointed out in my addition of def apply() to GenericCanBuildFrom
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19219 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 09:43:14 +00:00
extempore 429b986c82 Another warning for -Xstrict-warnings. This time it's those
beloved try/catch blocks which swallow all comers.  Realized
that two warnings are already one too many to combine under a
single option, and broke them out into individual options.

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19215 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-22 01:01:04 +00:00
extempore 8ebd26f97f Added -Ytailrecommend option. No longer must you wonder how
much tail recursion you're missing out on, if only you knew where
to sprinkle the finals and privates.  If the option is given it
will report on all methods it could have transformed.

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19212 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 22:06:43 +00:00
rompf 6f73c8f442 built new starr and fixed test cases
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19211 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 21:17:09 +00:00
rompf 572e769269 renamed Vector to IndexedSeq
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19210 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 21:13:58 +00:00
rompf 2b32279992 added methods updated +: :+ to SeqLike
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19209 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 21:05:42 +00:00
rompf b55cd51d56 added methods updated +: :+ to SeqLike
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19208 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 21:05:40 +00:00
rompf 4b8e5f88c9 scala.collection.Vector defaults to immutable
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19207 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 21:05:11 +00:00
extempore e406c12f04 A selection of cleanups stemming from recent investigations.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19206 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 20:57:27 +00:00
extempore 9f64daf9f5 Made Cursor.next tail recursive by making it final.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19205 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 19:54:48 +00:00
moors fad15cfbce refactoring of TypeVar to set the stage for tcpoly inference (also touched UndoLog, isHigherKinded logic in TypeRef)
added <:< implicit, should bootstrap

selection from squashed commit messages:
    commented out stuff so that this can be used to bootstrap and build a new starr
    merged/cherry picked refactorings unrelated to #2261
    (undoLog, cloneInternal, NoImplicitInfo)
    made conforms implicit, identity explicit
    replaced the implicit `identity` coercion by `conforms`, which can be used to encode generalised constraints
    the introduction of `conforms` revealed a bug in adaptToMember, which was inferring views while already inferring one, which gave rise to diverging implicits. Predef.identity is no longer special as far as the compiler is concerned.
    cleaned up isHigherKinded logic in TypeRef, and implemented it in TypeVar along with normalize
    added <:< to Predef: use as evidence for encoding generalized constraints
    (BTW: extractUndetparams clears undetparams: don't use in debug output -- I learned the hard way...)
    added todo about ticket 2066 -- branching from master to explicitkinds for fix
    refactoring: moved bounds tracking logic to TypeVar
    introduced typeConstructor in Type because we can't use appliedType(tp, List())) to strip a type's type arguments (appliedType is a no-op for empty args) -- don't want to pattern match on type either
    removed unused overrides in TypeVar (TODO double check)
    making appliedType more robust since it is now used more liberally -- neg/t0226 should no longer fail now
    merged in appliedType refactoring and added TypeVar logic to appliedType

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19204 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 18:33:45 +00:00
moors d2b4cfa170 added CanBuild type alias in package object scala.collection.generic
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19203 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 18:33:41 +00:00
odersky 18d8db1fb5 Fixed #2429. Added sortWith method over Ordering to SeqLike. Tentative fix for build problems on IBM's VM. changed output from explaintypes from < to <:.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19201 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 17:06:26 +00:00
extempore 2fe12fc8d5 Added some info to a tripping assertion.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19192 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 14:33:21 +00:00
moors aee2081937 fixed failing testcases due to previous commit (renaming of BuilderFactory)
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19191 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 13:55:41 +00:00
moors 3915263367 renamed BuilderFactory[El, To, From] -> CanBuildFrom[From, El, To] and added apply() overload to create collections from scratch generically
added def apply() overload to BuilderFactory so that we can also create collections from scratch generically
(see test test/files/pos/collectGenericCC.scala)

renaming:
- BuilderFactory[El, To, From] -> CanBuildFrom[From, El, To]
    bulk type-param reordering using: s/CanBuildFrom\[\s*([^,()\s]*)\s*,(\s+[^\s,()]*)\s*,\s+([^\s,()]*)\s*\]/CanBuildFrom[$3, $1,$2]/
    some argument lists got mixed up because they contained 4 comma's...
- builderFactory -> canBuildFrom

removed explicit implicit value in DocDriver that was renamed
renamed collection/generic/BuilderFactory.scala -> collection/generic/CanBuildFrom.scala

tested with clean build using ant strap.done -- everything went well on my machine

git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19190 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 13:24:41 +00:00
dragos eb68afef6b Made Platform methods inlineable and allow the optimiser to load code for methods that have the @inline attribute
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19189 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 13:19:33 +00:00
phaller d927529a38 Fix and test for #2446.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19183 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-21 10:08:34 +00:00
extempore 865bf27f75 Implementation of martin's suggested fix for #1503.
git-svn-id: http://lampsvn.epfl.ch/svn-repos/scala/scala/trunk@19170 5e8d7ff9-d8ef-0310-90f0-a4852d11357a
2009-10-20 22:18:21 +00:00