| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* 2.10.x: (51 commits)
improved/fixed reflection docs based on comments
Fixes SI-6354: improved error messages for Dynamic signature mismatches.
Add RedBlackTree tests for take/drop/slice.
Retain Ordering in drop/take/slice signatures.
test case closes SI-5770
clarify caveats of App trait
Remove `@static` annotation from the library.
New starr that does not depend on `@static`.
improved reflection documentation
pull request feedback
SI-5692 better error message
SI-5942 toolboxes now reset front ends
SI-6287 fixes synthetic symbol clashes in toolbox
Revert "Implement @static annotation on singleton object fields."
Revert "WIP add private/lazy checks and a few tests."
Revert "Fixes SI-6189."
Revert "Fixes SI-6236."
Revert "Fix SI-4581."
Revert "Fix SI-6294."
refactors java reflection tests
...
Conflicts:
src/compiler/scala/tools/nsc/typechecker/Typers.scala
src/partest/scala/tools/partest/package.scala
src/reflect/scala/reflect/internal/Trees.scala
|
| |\
| | |
| | | |
Rank based take/drop/slice
|
| | |
| | |
| | |
| | | |
Addresses review feedback by axel22.
|
| |\ \
| | | |
| | | | |
Fixes SI-6354: improved error messages for Dynamic signature mismatches.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
If an error occurs afer a Dynamic rewriting, augment the error message
with the rewritten tree and a hint to check the Dynamic method
signature.
|
| |\ \ \
| | |/ /
| |/| | |
SI-6287 fixes synthetic symbol clashes in toolbox
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Apparently synthetic classes like $anonfun$1 have two properties:
1) Their names are generated using a counter unique to a compilation unit
2) After flatten they levitate to the nearest enclosing package
As a result if we use an empty package to wrap toolbox codegen,
then this package will soon be overflown by $anonfun$1 symbols, because:
1) New codegen session = new compilation unit = new counter which starts at 0
2) New codegen session = new anon funs that end up as children of empty package
Creating a freshly named package for each codegen session fixed the problem.
Now anonfuns from different sessions end up with different parents.
|
| |\ \ \
| | | | |
| | | | | |
Scala reflection now supports Java CRTP
|
| | | | |
| | | | |
| | | | |
| | | | | |
All javac-produced artifacts are now placed into test/files/lib
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Enum members are static and, therefore, they need to be looked up in
classSymbol(<enum>).companionModule, rather than in classSymbol(<enum>).
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Because of using plain ExistentialType factory of a case class
typeToScala sometimes returned existentials with empty quantifieds.
Changing ExistentialType to newExistentialType, which simply returns
the underlying types if params are empty, fixed the problem.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Translation of Java types to Scala types has previously been
existentionalizing raw types of ParameterizedType arguments.
As shown in https://issues.scala-lang.org/browse/SI-6374
this leads to cyclic reference errors. If you wonder about the
mechanism of the error, take a look at the comments to the
aforementioned issue - there's a detailed explanation.
However calling rawToExistential is completely unnecessary, because
existential parameters of the results are immediately discarded,
and only prefix and symbol are used later on (which means that
existential extrapolation performed by rawToExistential also doesn't
after the result).
Finding out this was tough, but the rest was a piece of cake.
Getting rid of the call to rawToExistential when translating ParameterizedType
fixed the problem.
|
| |\ \ \ \
| | | | | |
| | | | | | |
SI-5767 fix + protecting public FlatHashMap API
|
| | | | | | |
|
| |\ \ \ \ \
| | | | | | |
| | | | | | | |
Revert `@static` annotation
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
This reverts commit 892ee3df93a10ffe24fb11b37ad7c3a9cb93d5de with
exception of keeping `@static` annotation in the library so we
can deploy a new starr that does not depend on it before removing
it completely.
Conflicts:
src/compiler/scala/tools/nsc/backend/icode/GenICode.scala
src/compiler/scala/tools/nsc/backend/jvm/GenJVM.scala
src/compiler/scala/tools/nsc/transform/CleanUp.scala
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
This reverts commit 227239018b38ab7218ee6b30493c9c8e1836c8c9.
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
This reverts commit 5a8dfad583b825158cf0abdae5d73a4a7f8cd997.
Conflicts:
src/compiler/scala/tools/nsc/backend/icode/GenICode.scala
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
This reverts commit faa114e2fb6003031efa2cdd56a32a3c44aa71fb.
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
This reverts commit 373f22a2022519ab894c1ea77460e6460d7c2ee4.
|
| | | |_|/ /
| | |/| | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
This reverts commit cb393fcbe35d0a871f23189d791b44be1b826ed2.
Conflicts:
src/compiler/scala/tools/nsc/backend/icode/GenICode.scala
|
| |\ \ \ \ \
| | | | | | |
| | | | | | | |
SI-5692 better error message
|
| | |/ / / /
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Doesn't fix the underlying issue with macros and type inference,
but at least now the error message says exactly what needs to be done
to make the error go away.
|
| |/ / / /
| | | | |
| | | | |
| | | | |
| | | | | |
FrontEnd => Reporter proxy now correctly redirects
flush and reset back to the underlying front end.
|
| |\ \ \ \
| | | | | |
| | | | | | |
Fixed SI-6353: applyDynamic with sugared applications
|
| | | |/ /
| | |/| |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
- Accept sugared applications such as x(1) if x implements Dynamic,
so x(1) gets re-written to x.apply(1).
- When picking a dynamic rewrite for x.apply(1), favor applyDynamic
instead of the default selectDynamic.
|
| |\ \ \ \
| | | | | |
| | | | | | |
moves isImplicit from TermSymbol to Symbol
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Because classes can also be implicit.
|
| |\ \ \ \ \
| | | | | | |
| | | | | | | |
Topic/empty array
|
| | | |/ / /
| | |/| | |
| | | | | |
| | | | | | |
This reverts most of commit 9d84e89d2 .
|
| |\ \ \ \ \
| | |/ / / /
| |/| | | | |
SI-6336 Disallows value types in structuralal refinements
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Structural refinements already have a number of restrictions, e.g. cannot refer to
type parameters of enclosing classes. We need to disallow value classes as well.
|
| |\ \ \ \ \
| | |_|/ / /
| |/| | | | |
test suite for SI-6329
|
| | | | | | |
|
| | |/ / /
| |/| | |
| | | | |
| | | | |
| | | | | |
Except for one thingie: java enums are currently not understood
by Scala reflection, hence they aren't yet supported in annotations.
|
| |\ \ \ \
| | | | | |
| | | | | | |
cleaning up reflection
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
1) parseExpr => parse
2) runExpr => eval
3) Introduces compile(Tree): () => Any, since it has frequent uses
|
| |\ \ \ \ \
| | | | | | |
| | | | | | | |
A little cleanup along the Any to AnyRef trail.
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Followup to 35316be and d3f879a.
- Remove obsolete comments and replace them with a test.
- Don't emit error addendum unless we know we're dealing
with a value class.
|
| |\ \ \ \ \ \
| | | | | | | |
| | | | | | | | |
Fix for SI-6245 with workaround for SI-2296.
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
protected/super accessor issue: Don't subvert the creation of the
standard protected accessor with the java interop accessor. For
SI-2296, the compiler emits an error instead of causing an illegal
access error at runtime.
|
| |\ \ \ \ \ \ \
| | |_|_|/ / / /
| |/| | | | | | |
Topic/empty array optimization
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
Because there are lots of times when you just need an
array and shouldn't have to allocate one every time or
pick a random spot to cache yet another empty array.
|
|\ \ \ \ \ \ \ \
| | | | | | | | |
| | | | | | | | | |
Fix for SI-6305 & new actor migration tests
|
| | | | | | | | | |
|
| | | | | | | | | |
|
|\ \ \ \ \ \ \ \ \
| |/ / / / / / / /
|/| / / / / / / /
| |/ / / / / / /
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
* origin/2.10.x: (68 commits)
Eliminate breaking relative names in source.
"Hot fix" for broken build.
Fix SI-4813 - Clone doesn't work on LinkedList.
Made 'def clone()' consistent with parens everywhere.
accommodates pull request feedback
SI-6310 redeploys the starr
SI-6310 AbsTypeTag => WeakTypeTag
SI-6323 outlaws free types from TypeTag
SI-6323 prohibits reflection against free types
improvements for reification of free symbols
removes build.newFreeExistential
SI-6359 Deep prohibition of templates in value class
Fixes SI-6259. Unable to use typeOf in super call of top-level object.
Fixes binary repo push for new typesafe repo layouts.
Better error message for pattern arity errors.
Rescued TreeBuilder from the parser.
Pending test for SI-3943
Test case for a bug fixed in M7.
Fix for SI-6367, exponential time in inference.
SI-6306 Remove incorrect eta-expansion optimization in Uncurry
...
Conflicts:
src/compiler/scala/tools/nsc/transform/AddInterfaces.scala
src/compiler/scala/tools/nsc/transform/SpecializeTypes.scala
|
| |/ / / / / /
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
These things are killing me. Constructions like
package scala.foo.bar.baz
import foo.Other
DO NOT WORK in general. Such files are not really in the
"scala" package, because it is not declared
package scala
package foo.bar.baz
And there is a second problem: using a relative path name means
compilation will fail in the presence of a directory of the same
name, e.g.
% mkdir reflect
% scalac src/reflect/scala/reflect/internal/util/Position.scala
src/reflect/scala/reflect/internal/util/Position.scala:9: error:
object ClassTag is not a member of package reflect
import reflect.ClassTag
^
src/reflect/scala/reflect/internal/util/Position.scala:10: error:
object base is not a member of package reflect
import reflect.base.Attachments
^
As a rule, do not use relative package paths unless you have
explicitly imported the path to which you think you are relative.
Better yet, don't use them at all. Unfortunately they mostly work
because scala variously thinks everything scala.* is in the scala
package and/or because you usually aren't bootstrapping and it
falls through to an existing version of the class already on the
classpath.
Making the paths explicit is not a complete solution -
in particular, we remain enormously vulnerable to any directory
or package called "scala" which isn't ours - but it greatly
limts the severity of the problem.
|
| |\ \ \ \ \ \
| | | | | | | |
| | | | | | | | |
SI-6331 deconst If type / refine equality of floating point Constant types.
|