| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Environment parameters do not count in th eresult type.
|
|
|
|
|
|
|
|
| |
Some transformations encounter applications where new arguments ahve to be
supplied. The method type already accounts for these argument but the
Application node passed into TreeTransform#transformApply is constructed
with a cpy.Apply operation which does a type assignment. That type assignment
fails with a parameter mismatch unless relaxedTyping is on.
|
|
|
|
| |
It changes meaning drastically so should always be visible.
|
|
|
|
|
|
| |
Previously, we determined the default getters solely from the method TermRef type.
This is wrong if the method is prefix is not a path -- the prefix of the term ref will be a
TypeRef and the getter selection will be a SelectFromType tree, which makes no sense.
|
|
|
|
| |
Advantage: Can rename typed as well as untyped trees.
|
|
|
|
|
| |
Lifting an application `f(arg1).f(args)` requires lifting of the whole prefix
`f(arg1)`, because `f` might have a side effect.
|
| |
|
|
|
|
|
| |
Instead of requiring to be called a given phase, change the context if
that is not the case.
|
|
|
|
|
| |
The idea to traverse with currently enclosing methid is also used in
LambdaLift and could be used elsewhere.
|
|
|
|
| |
Use ref and appliedTo instead.
|
|\
| |
| | |
Pattern matcher
|
| |
| |
| |
| | |
from pr #174.
|
| |
| |
| |
| |
| | |
see discussion in
https://github.com/dotty-staging/dotty/commit/0c551f00f43c1675aca3adbff7567f47432c66f6
|
| |
| |
| |
| |
| | |
Makes it less confusing as thisTransformer is already used
for the ExplicitOuter itself
|
| | |
|
| |
| |
| |
| | |
isRef is more efficient than subtyping check.
|
| |
| |
| |
| |
| | |
1) strip TypeVars wehere necessary before widening
2) allow the combination of widening and dealiasing, in any order.
|
| | |
|
| | |
|
| |
| |
| |
| | |
.denot was missing
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| | |
And a test for this.
|
| |
| |
| |
| | |
refchecks
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| | |
Unit tests still to-be-fixed
|
| |
| |
| |
| |
| | |
When lazy val body is moved to a init method the owner of symbols in
tree should change
|
| | |
|
| | |
|
| |
| |
| |
| | |
Now reuse symbols from typer. Less substitutions -> better performance.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Implementation of pattern
sel match {
x => <body>
}
used to replace references to x by references to sel in <body>.
This is not type correct and it also requires additional traversal of
body.
Now SubstOnlyTreeMaker generates a `x = sel` statement.
|
| |
| |
| |
| |
| |
| | |
Like other synthetic methods, productArity will not be generated
if an explicit definition is given. Used to be generated unconditionally
in desugaring.
|
| |
| |
| |
| |
| |
| | |
Move flag that throws exception on deep subtyping stacks from Config varianble to setting.
Disable setting for core-pickling which had a deep subtype failure after pattern matcher
was integrated. Todo: Figure out why the subtype stack got so deep.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The problem is running changeOwner(from, to) where
- from is a ValDef or a Label
- an embedded definition has as owner not `from` but some
owner of `from`.
We allow such denomrlaized owners and the pattern matcher generates
them. This patch makes changeOwner take these situations into account.
|
| |
| |
| |
| | |
Can handle now vararg arguments in patterns.
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
Previous postcondition checking did not take into account that phases are
not flat - they consist in part of macro phases that contain miniphases.
In fact the whole set up in Run is dubiuos - we should eliminate the problem at the
root, as described in the TODO in run.
|
| |
| |
| |
| | |
@odersky there are some tests disabled, which failed due to other phases being able to transform more code.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
TypeVars can appear as keys in baseType caches. The problem is that
their base types depend on their instantiation, which is not always
know yet when the test is performed. So results of baseType on
type variables should never be cached.
Todo: check whether there are any other caching problems involving typevars.
Conflicts:
src/dotty/tools/dotc/core/SymDenotations.scala
|
| | |
|
| |
| |
| |
| | |
testOnly dotc.tests
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
GADT bound resetting may only be applied when comparing
<pattern type> <: <expected type>, not when comparing the
other way around.
The fix revealed an error in a test case (t1048) which looks like a real error.
Therefore the test got moved to neg.
Conflicts:
src/dotty/tools/dotc/typer/Applications.scala
test/dotc/tests.scala
tests/disabled/t1048.scala
|
| |
| |
| |
| | |
Indicating that pt is type of selector is this pattern match makes it easier to follow.
|
| |
| |
| |
| |
| | |
Except t1048 which infers incorrect type in typer, patmat creates a tree that computes a more precise one that fails to typecheck
Disabling erasure due to dozens of "Type BLA is illegal after erasure" errors.
|
| | |
|