diff options
author | Martin Odersky <odersky@gmail.com> | 2013-11-07 21:43:59 +0100 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2013-11-07 21:43:59 +0100 |
commit | 067ef2076cfcf7864b840ddf38c514ff67f52c64 (patch) | |
tree | 3b974ba717ecc08ab37d8dfb49c02f4f74d5eb5a /src/dotty/tools/dotc/typer/Mode.scala | |
parent | 514801453e240610a0ba68fff7305355a7d204e1 (diff) | |
download | dotty-067ef2076cfcf7864b840ddf38c514ff67f52c64.tar.gz dotty-067ef2076cfcf7864b840ddf38c514ff67f52c64.tar.bz2 dotty-067ef2076cfcf7864b840ddf38c514ff67f52c64.zip |
Fixing inference problem and block scope problem
1. Typing blocks: forgot to create new scope. Now fixed.
2. The decitsion whether to interpolate a type variable was made based on the type variable's position and the current tree's position. This is too imprecise, because we might have auto-generated trees where all important parts have the same position. We now check for actual tree containment: A type variable can be interpolated for the type of a tree T if T contains the tree which introduced the type variable.
Diffstat (limited to 'src/dotty/tools/dotc/typer/Mode.scala')
-rw-r--r-- | src/dotty/tools/dotc/typer/Mode.scala | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/src/dotty/tools/dotc/typer/Mode.scala b/src/dotty/tools/dotc/typer/Mode.scala index e126a794d..1890822b6 100644 --- a/src/dotty/tools/dotc/typer/Mode.scala +++ b/src/dotty/tools/dotc/typer/Mode.scala @@ -31,7 +31,6 @@ object Mode { val ImplicitsEnabled = newMode(2, "ImplicitsEnabled") val InSuperInit = newMode(3, "InSuperInit") - val RestrictedInterpolation = newMode(4, "RestrictedInterpolation") val PatternOrType = Pattern | Type }
\ No newline at end of file |