diff options
author | schinz <schinz@epfl.ch> | 2003-05-14 13:05:56 +0000 |
---|---|---|
committer | schinz <schinz@epfl.ch> | 2003-05-14 13:05:56 +0000 |
commit | 74be7e83e5b49f9f7906d6b17966a544511d8322 (patch) | |
tree | 21e4abfdb898d1b1644d2fa50daf87d63627ce59 | |
parent | ca14451a52d8cd23e332a8f7881752ac2053bc79 (diff) | |
download | scala-74be7e83e5b49f9f7906d6b17966a544511d8322.tar.gz scala-74be7e83e5b49f9f7906d6b17966a544511d8322.tar.bz2 scala-74be7e83e5b49f9f7906d6b17966a544511d8322.zip |
- use the name of the symbol to identify class ...
- use the name of the symbol to identify class constructors instead of
isConstructor method (which doesn't work with constructors added by
AddConstructors)
-rw-r--r-- | sources/scala/tools/scalai/Environment.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sources/scala/tools/scalai/Environment.java b/sources/scala/tools/scalai/Environment.java index 51867abca0..f221c8f4db 100644 --- a/sources/scala/tools/scalai/Environment.java +++ b/sources/scala/tools/scalai/Environment.java @@ -17,6 +17,7 @@ import scalac.symtab.Symbol; import scalac.symtab.Type; import scalac.symtab.Scope; import scalac.symtab.Scope.SymbolIterator; +import scalac.util.Names; import scalac.util.Debug; public class Environment { @@ -110,7 +111,7 @@ public class Environment { Object value = functions.get(symbol); if (value != null) return (Function)value; if (symbol.isJava()) { - Function function = symbol.isConstructor() ? + Function function = (symbol.name == Names.CONSTRUCTOR) ? Function.JavaConstructor(mirror.getConstructor(symbol)) : Function.JavaMethod(mirror.getMethod(symbol)); return insertFunction(symbol, function); |