| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
The captured context was passed implicitly to dd.rhs, atGroupEnd is
always run with the same runId as the captured context so this should be okay,
but it's better to avoid using two contexts in the same expression anyway.
|
|
|
|
|
|
|
|
| |
* Add `isSyntheticFunction` checks for synthetic functions such as FuntionN
for N > 22 and ImplicitFunctionN for N >= 0.
* Add `erasedFunctionClass` to get the erased verion of synthetic functions.
* Change the semantics of `isFunctionClass` to return true if it is any kind of
FunctionN or ImplicitFunctionN.
|
|\
| |
| | |
Fix #1916: fix erasure of implicit xxl closures
|
| |
| |
| |
| | |
This commit extends the fix done in #1920 to implicit closures.
|
|/
|
|
|
|
|
|
| |
This has two advantages:
- We can distinguish BackquotedIdent from Ident, allowing the user to
use a defined "type `&`", see testcase.
- We get better positions for the operators. This is useful in IDEs, for
example to get the type at point.
|
|\
| |
| | |
[doctool] Add markdown support && Static site generation
|
| | |
|
| | |
|
| | |
|
|\ \
| | |
| | | |
Fix-#1723: Avoid private leaks on completion
|
| | |
| | |
| | |
| | | |
As #1723 demonstrates, doing this at PostTyper is too late.
|
|\ \ \
| |_|/
|/| | |
Fix #1915 Synthetic function traits need NoInits flag
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When compiled from Scala2 that knowledge was lost. Normally that
would be not a problem (e.g. the same thing happens for Function0-22).
But FunctionXXL is special in that it is inherited only after erasure.
Since `augmentScala2Trait` runs before erasure, it is having no effect
on FunctionXXL itself when running on classes that inherit function types of
large arities. Therefore, FunctionXXL is missing an implementation class
at phase Mixin, which means that the supercall logic which rewires
super.<init> to implementation class init cannot work. This leaves us
with a super.<init> to FunctionXXL in `i1915.scala`.
The fix is to always know that `FunctionXXL` has no init method, so
no super.<init> will be generated for it.
|
|/
|
|
|
| |
xxl closures need to get the SAM type FunctionXXL as their explicit
type field after ersure.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Illegal class overrides are fundamentally at odds with the way dotty
represents types and therefore can cause lots of low-level problems.
Two measures in this commit
First, we detect direct illegal class overrides on completion instead of
during RefChecks. Break the override by making the previously
overriding type private.
This fixes i1750.scala, but still fails for indirect overrides between
two unrelated outer traits/classes that are inherited by the same class or trait.
We fix this by catching the previously thrown ClassCastException
in both ExtractAPI and RefChecks.
Test case for indirect overrides is in i1750a.scala.
|
|\
| |
| | |
Add sbt-based bootstrap
|
| | |
|
| |
| |
| |
| |
| | |
Using changeOwnerAfter would be more appropriate but currently fails
with an assertion in LambdaLift
|
|/
|
|
|
|
|
|
|
| |
Previous version precomputed everything needed to make the final decision.
This was fast-path for method that will be tail-rec transformed.
Unfortunatelly, in case decision was not to tail-rec optimize it could have
led to exponential number of transformations.
Now, the fast-path is for methods that will not.
|
|\
| |
| | |
Fix #1877: Add forwarders for primitive/generic mixins.
|
| | |
|
| | |
|
| | |
|
| | |
|
|/
|
|
| |
This reverts commit 63d68bf4d3cbac82f6d9faf19acd5589603a17ee.
|
|\
| |
| | |
Fix #1865: Compute outer path at right phase
|
| | |
|
| |
| |
| |
| |
| | |
When computing the outer path, we need to be careful to dealias before erasure,
even if the outer path is demanded during erasure. Otherwise we lose prefixes.
|
| | |
|
|/
|
|
|
|
| |
If a by-name arg has a bottom type, we need to create a closure with the
result type of the formal parameter, or else specialization with
FunctionalInterfaces will fail.
|
|
|
|
|
|
| |
Fixing two failures in stdlib having to do with widening. In both
cases, a widenIfUnstable was required. One was widening too much,
the other too little.
|
|
|
|
|
|
|
| |
We looked under the wrong signature before, which meant that
we sometimes would not detect that a super accessor existed
already and generate a duplicate. Observed when compiling
stdlib's collection/mutable/ObservableMap.scala.
|
|\
| |
| | |
Fix #1820: make sure outer of traits implemented
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Previously, we don't generate `outer` for the anonymous class `new Inner2 {}`.
This is incorrect, as `Inner2 {}` extends `A.Inner`, which requires an outer.
trait A {
val a = "a"
trait Inner {
def f = println(a)
def h = 3
}
}
trait B extends A {
trait Inner2 extends Inner
new Inner2 {}
}
|
| | |
|
|\ \
| |/
|/| |
Add implicit function types
|
| | |
|
| | |
|
| |
| |
| |
| | |
Also, integrate Jason's test case with the conditional.
|
| |
| |
| |
| |
| | |
Introduce an option to not specialize monomorphic
targets of callsites.
|
| |
| |
| |
| |
| | |
Optimizes implicit closures by avoiding closure
creation where possible.
|
| |
| |
| |
| | |
and check at runtime that it works
|
|\ \
| |/
|/| |
Fix #1755: Make sure references in outer args are accessible
|
| |
| |
| |
| |
| |
| |
| | |
Needed a fixup action in ExplicitOuter to avoid references to
module's This from outside their scope.
The problem is fixed, but I wish I understood better the root cause.
|
|\ \
| | |
| | | |
Fix #1810 LazyVals should use changeOwnerAfter.
|
| | | |
|
|\ \ \
| | | |
| | | | |
Fix emission of annotations
|
| | | |
| | | |
| | | |
| | | |
| | | | |
Previously we replaced them by ConcreteAnnotation so they became regular
annotations and could be emitted in some cases. They need to keep being BodyAnnotation.
|