| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
These were not handled before.
|
|\
| |
| | |
Added elimLocals miniphase
|
|/
|
|
|
|
|
| |
This phase drops the Local flag from all private[this] and protected[this] members.
This allows subsequent code motions where code is moved from a class to its
companion object. It invalidates variance checking, which is consequently disabled
when retyping.
|
|\
| |
| | |
transform/variance
|
| |
| |
| |
| | |
Disabled for now, awaiting a fix.
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
Variance checking is now run as part of type-checking.
Fixed tests that exhibited variance errors. Added tests where some classes of
variance errors should be detected.
|
| |
| |
| |
| |
| |
| | |
1) Type parameter accessors inherit their variance from the type parameter
2) Copy method parameter defaults are annotated @uncheckedVariance. This is
necessary because default methods will be checked for variance.
|
| |
| |
| |
| |
| | |
It was unmaintained and superseded by TreeChecker. The only needed bit,
escapingRefs, got moved to Typer.
|
| |
| |
| |
| | |
Not yet integrated or tested.
|
| | |
|
| | |
|
|/
|
|
|
| |
Added OverridingPairs
Small tweaks here and there.
|
|\
| |
| | |
Enable improved incremental compilation (name hashing)
|
| |
| |
| |
| |
| | |
The algorithm is stable enough to try it out for dotty build. It's
enabled in sbt and Akka already.
|
|\ \
| |/
|/| |
Transform/repeated
|
| |
| |
| |
| |
| |
| | |
Currently we cannot run this test automatically because the testing framework
does not know about .java files. It was run manually and verified that ElimRepeated
does was it is supposed to do (create a varargs bridge).
|
| |
| |
| |
| |
| |
| | |
Now inserts a bridge whenever a method overrides a Java varargs method.
This is conservative but safe. We might use a more aggressive scheme, as
the one in Scala 2, but it's not clear the win would warrant it.
|
| |
| |
| |
| | |
... and moved to TypeApplications.
|
| |
| |
| |
| |
| | |
Did not work for this prefixes and other singleon types before.
I.d. was generating a SelectFromType tree, which is wrong.
|
| |
| |
| |
| |
| | |
Distinguish translations between Java and Scala varargs methods
and add bridges where needed.
|
| |
| |
| |
| | |
so that sig(<repeated>[T]) = sig(Seq[T]).
|
|/
|
|
|
|
|
| |
Having two repeated param classes (and two types) does not work,
because we need to maintain an overriding relationship between
Scala repeated param methods and Java repeated param methods (this
will be resolved later by bridges).
|
|\
| |
| | |
Tailrec tc
|
| | |
|
| |
| |
| |
| |
| | |
Used in FullParameterization to substitute type parameters.
Fixes test failure for t2399.scala
|
| |
| |
| |
| | |
Hurray!
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
TailRec now relies on FullParameterization and uses two passes
for transformation. First one decides weather the method will
be transformed and if yes, starts rewriting calls in taill position.
Second one lifts the method body to a fully parameterized one,
correcting types.
|
| |
| |
| |
| | |
Test for order of type parameters in recursive call
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If some node in tree is transformed changing the type,
the outer node could potentially also change type.
This patch implements a RetypingTreeMap that propagates those
changes until types converge. Propagation is done for tree nodes
that are able to compute their type based on their children:
Pair, Block, If, Match, CaseDef, Try, SeqLiteral, Annotated, Select.
|
|/ |
|
|\
| |
| | |
Fix of FullParameterization
|
| |
| |
| |
| | |
Avoid substitituting A.this if A is a globally accesisble mdoule.
|
|\ \
| | |
| | | |
fix/#148
|
| |/
| |
| |
| | |
Fixed typo in Splitter. Closes #148.
|
|\ \
| | |
| | | |
Fixed typo
|
| |/ |
|
|\ \
| | |
| | | |
Fixed #143
|
| | | |
|
| |/
| |
| |
| |
| | |
The problem was that TermRefWithSignatures did not take shadowed names into account
when reconstituting themselves under a new prefix.
|
| | |
|
|/ |
|
|\
| |
| | |
Transform/extension methods
|
| |
| |
| |
| | |
Can now decide on rewiring on a node-by-nide basis.
|
| |
| |
| |
| | |
Adapt the transformation so that self types are handled correctly.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
In a situation like
class C { this: D =>
}
the effective self type of the class is taken to be D & C.
Why? First, Scala 2.x does it that way. Second, it's needed to make the
FullParameterization transform go though.
|
| |
| |
| |
| | |
Problem was reported by @darkdimius. Test case will come in next commit.
|
| |
| |
| |
| |
| |
| |
| | |
t6574 has a new test where we produce identical code in an if-then-else. This broke
the rewiring logic before, and is fixed now.
Also, more comments and test cases.
|
| |
| |
| |
| |
| |
| | |
Methods dealing with fully parameterized versions of classes were
pulled from `TypeUtils` and `ExtensionMethods` into `FullyParameterization`.
`TypeUtils` is left for possible future use, but is empty right now.
|