diff options
Diffstat (limited to 'sources/scalac/symtab/Definitions.java')
-rw-r--r-- | sources/scalac/symtab/Definitions.java | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sources/scalac/symtab/Definitions.java b/sources/scalac/symtab/Definitions.java index 9e269348c6..e8450ef265 100644 --- a/sources/scalac/symtab/Definitions.java +++ b/sources/scalac/symtab/Definitions.java @@ -67,6 +67,7 @@ public class Definitions { public final Symbol EQEQ; public final Symbol BANGEQ; public final Symbol EQUALS; + public final Symbol EQ; public final Symbol TOSTRING; public final Symbol HASHCODE; @@ -230,6 +231,7 @@ public class Definitions { // the scala.ANYVAL class ANYVAL_CLASS = getClass(Names.scala_AnyVal); + ANYVAL_CLASS.flags |= Modifiers.SEALED; ANYVAL_TYPE = ANYVAL_CLASS.typeConstructor(); // the scala.ALL class @@ -347,6 +349,12 @@ public class Definitions { BOOLEAN_TYPE)); ANY_CLASS.members().enter(EQUALS); + EQ = new TermSymbol( + Position.NOPOS, Names.eq, ANY_CLASS, 0); + EQ.setInfo(Type.MethodType(new Symbol[]{newParameter(EQ, JAVA_OBJECT_TYPE)}, + BOOLEAN_TYPE)); + ANY_CLASS.members().enter(EQ); + TOSTRING = new TermSymbol( Position.NOPOS, Names.toString, ANY_CLASS, 0); TOSTRING.setInfo(Type.MethodType(Symbol.EMPTY_ARRAY, STRING_TYPE)); |