aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2014-08-18 13:24:51 +0200
committerMartin Odersky <odersky@gmail.com>2014-08-18 13:24:51 +0200
commit49cc900b22394f039c3f10d3f8d7cafcf9148e3a (patch)
tree83d6d11f244d41bc6f0be1560a28869099a2d16c
parentc71643b9087f1de218dfc2d3a1aefc97984c3b8e (diff)
downloaddotty-49cc900b22394f039c3f10d3f8d7cafcf9148e3a.tar.gz
dotty-49cc900b22394f039c3f10d3f8d7cafcf9148e3a.tar.bz2
dotty-49cc900b22394f039c3f10d3f8d7cafcf9148e3a.zip
Fix to isAnonymousClass
-rw-r--r--src/dotty/tools/dotc/core/SymDenotations.scala2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/dotty/tools/dotc/core/SymDenotations.scala b/src/dotty/tools/dotc/core/SymDenotations.scala
index a19f824e5..bd269bbcc 100644
--- a/src/dotty/tools/dotc/core/SymDenotations.scala
+++ b/src/dotty/tools/dotc/core/SymDenotations.scala
@@ -325,7 +325,7 @@ object SymDenotations {
/** Is this symbol an anonymous class? */
final def isAnonymousClass(implicit ctx: Context): Boolean =
- initial.asSymDenotation.name startsWith tpnme.ANON_CLASS
+ isClass && (initial.asSymDenotation.name startsWith tpnme.ANON_CLASS)
/** Is symbol a primitive value class? */
def isPrimitiveValueClass(implicit ctx: Context) = defn.ScalaValueClasses contains symbol