aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/typer
diff options
context:
space:
mode:
authorFelix Mulder <felix.mulder@gmail.com>2016-09-04 19:27:09 +0200
committerFelix Mulder <felix.mulder@gmail.com>2016-10-06 17:45:38 +0200
commitaf27562040631d0bea38ec3ff8912fda9939f34e (patch)
treec1984c9147ee9271d6f535af006df65e0073e4b2 /src/dotty/tools/dotc/typer
parent49b19933dc23220e582016fc0bfd0b35961d61a1 (diff)
downloaddotty-af27562040631d0bea38ec3ff8912fda9939f34e.tar.gz
dotty-af27562040631d0bea38ec3ff8912fda9939f34e.tar.bz2
dotty-af27562040631d0bea38ec3ff8912fda9939f34e.zip
Typecheck usecases in fresh local scope
Diffstat (limited to 'src/dotty/tools/dotc/typer')
-rw-r--r--src/dotty/tools/dotc/typer/Typer.scala3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/dotty/tools/dotc/typer/Typer.scala b/src/dotty/tools/dotc/typer/Typer.scala
index b24fc6237..3291cb9d0 100644
--- a/src/dotty/tools/dotc/typer/Typer.scala
+++ b/src/dotty/tools/dotc/typer/Typer.scala
@@ -1247,8 +1247,7 @@ class Typer extends Namer with TypeAssigner with Applications with Implicits wit
val dummy = localDummy(cls, impl)
val body1 = typedStats(impl.body, dummy)(inClassContext(self1.symbol))
- if (ctx.settings.Ydocrun.value)
- typedUsecases(body1.map(_.symbol), self1.symbol)
+ typedUsecases(body1.map(_.symbol), self1.symbol)(localContext(cdef, cls).setNewScope)
checkNoDoubleDefs(cls)
val impl1 = cpy.Template(impl)(constr1, parents1, self1, body1)