diff options
author | Eugene Vigdorchik <eugenevigdorchik@epfl.ch> | 2011-01-16 19:10:44 +0000 |
---|---|---|
committer | Eugene Vigdorchik <eugenevigdorchik@epfl.ch> | 2011-01-16 19:10:44 +0000 |
commit | bce484e2371b9a264565fc5e1cac2815bed8d79b (patch) | |
tree | 813c6dfde78e95ecbd4dce781a170acf8e7caebb | |
parent | e89b53d7e1f0ec376bd237fbaa8d7a19928e020e (diff) | |
download | scala-bce484e2371b9a264565fc5e1cac2815bed8d79b.tar.gz scala-bce484e2371b9a264565fc5e1cac2815bed8d79b.tar.bz2 scala-bce484e2371b9a264565fc5e1cac2815bed8d79b.zip |
Do not redefine the symbol in a class file to p...
Do not redefine the symbol in a class file to prevent spurious errors
in IDE. IDE creates a second copy in owner scope and unlinks it when
finished. Review by odersky
-rw-r--r-- | src/compiler/scala/tools/nsc/interactive/Global.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/compiler/scala/tools/nsc/interactive/Global.scala b/src/compiler/scala/tools/nsc/interactive/Global.scala index a563b25f44..a816413295 100644 --- a/src/compiler/scala/tools/nsc/interactive/Global.scala +++ b/src/compiler/scala/tools/nsc/interactive/Global.scala @@ -656,7 +656,7 @@ self => * Since the IDE rechecks units several times in the same run, these tests * are disabled by always returning true here. */ - override def canRedefine(sym: Symbol) = true + override def canRedefine(sym: Symbol) = sym.sourceFile ne null def typeCheck(unit: CompilationUnit): Unit = { activeLocks = 0 |