diff options
author | schinz <schinz@epfl.ch> | 2003-03-10 08:20:25 +0000 |
---|---|---|
committer | schinz <schinz@epfl.ch> | 2003-03-10 08:20:25 +0000 |
commit | 1fb5a195b5575e7015be4fd1ee8f89116a78cfb5 (patch) | |
tree | 3d4af44398291fadaf5af44a6503708a02bb2d4e /sources | |
parent | ce0cb58ff3182e6c79b1947c20024b8999183394 (diff) | |
download | scala-1fb5a195b5575e7015be4fd1ee8f89116a78cfb5.tar.gz scala-1fb5a195b5575e7015be4fd1ee8f89116a78cfb5.tar.bz2 scala-1fb5a195b5575e7015be4fd1ee8f89116a78cfb5.zip |
- bug fix: correctly detect calls to constructors
- bug fix: do not add nested interfaces as fields
Diffstat (limited to 'sources')
-rw-r--r-- | sources/scalac/backend/jvm/GenJVM.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sources/scalac/backend/jvm/GenJVM.java b/sources/scalac/backend/jvm/GenJVM.java index cafd3d10e6..ba38f31e45 100644 --- a/sources/scalac/backend/jvm/GenJVM.java +++ b/sources/scalac/backend/jvm/GenJVM.java @@ -66,7 +66,7 @@ class JVMGenerator { protected final static String CONSTRUCTOR_STRING = Constants.CONSTRUCTOR_NAME; protected final static Name CONSTRUCTOR_NAME = - Name.fromString(CONSTRUCTOR_STRING); + Name.fromString(CONSTRUCTOR_STRING).toConstrName(); protected Unit unit = null; protected String sourceFileName = null; @@ -562,7 +562,7 @@ class JVMGenerator { Scope.SymbolIterator memberIt = cSym.members().iterator(); while (memberIt.hasNext()) { Symbol member = memberIt.next(); - if (!member.isMethod()) { + if (member.isTerm() && !member.isMethod()) { FieldGen fGen = new FieldGen(modifiersStoJ(member.flags), typeStoJ(member.info()), member.name.toString(), @@ -1328,7 +1328,7 @@ class JVMGenerator { default: { Symbol sym = tp.symbol(); if (sym == Symbol.NONE) - return null; + throw global.fail("invalid type ", tp); else if (typeMap.containsKey(sym)) return (Type)typeMap.get(sym); else { |