diff options
author | Martin Odersky <odersky@gmail.com> | 2017-02-18 17:40:59 +0100 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2017-02-18 17:40:59 +0100 |
commit | db295e8fb13c8490b96d84e8357a75550ebdebfd (patch) | |
tree | 533a3c5f691829e19c7eb5691cb68ef2ccedc970 /compiler | |
parent | cf9741297a8bb91a26841d970be38436565a62c8 (diff) | |
download | dotty-db295e8fb13c8490b96d84e8357a75550ebdebfd.tar.gz dotty-db295e8fb13c8490b96d84e8357a75550ebdebfd.tar.bz2 dotty-db295e8fb13c8490b96d84e8357a75550ebdebfd.zip |
Fix default parameter value.
Interesting that the tests pass even if we always assume outOfContext = true.
So this raises the question why have a flag? It's just that I am not sure the
`outOfContext` behavior is correct in all cases. So I prefer to be conservative
here.
Diffstat (limited to 'compiler')
-rw-r--r-- | compiler/src/dotty/tools/dotc/transform/ExplicitOuter.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/src/dotty/tools/dotc/transform/ExplicitOuter.scala b/compiler/src/dotty/tools/dotc/transform/ExplicitOuter.scala index cb74f601f..3cfbdf454 100644 --- a/compiler/src/dotty/tools/dotc/transform/ExplicitOuter.scala +++ b/compiler/src/dotty/tools/dotc/transform/ExplicitOuter.scala @@ -364,7 +364,7 @@ object ExplicitOuter { */ def path(toCls: Symbol, start: Tree = This(ctx.owner.lexicallyEnclosingClass.asClass), - outOfContext: Boolean = true): Tree = try { + outOfContext: Boolean = false): Tree = try { def loop(tree: Tree): Tree = { val treeCls = tree.tpe.widen.classSymbol val outerAccessorCtx = ctx.withPhaseNoLater(ctx.lambdaLiftPhase) // lambdalift mangles local class names, which means we cannot reliably find outer acessors anymore |