diff options
author | Martin Odersky <odersky@gmail.com> | 2005-03-02 14:56:32 +0000 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2005-03-02 14:56:32 +0000 |
commit | 9acfa7693d146fc2ea6fdad61c74907354910ea8 (patch) | |
tree | e0832025736b165bd7e087b3bab41d4fb0046fe0 /sources/scala/tools/nsc/symtab/classfile/ClassfileParser.scala | |
parent | f8c47c369ed0254ea3bda3366b9902b1a3dd5ba2 (diff) | |
download | scala-9acfa7693d146fc2ea6fdad61c74907354910ea8.tar.gz scala-9acfa7693d146fc2ea6fdad61c74907354910ea8.tar.bz2 scala-9acfa7693d146fc2ea6fdad61c74907354910ea8.zip |
*** empty log message ***
Diffstat (limited to 'sources/scala/tools/nsc/symtab/classfile/ClassfileParser.scala')
-rwxr-xr-x | sources/scala/tools/nsc/symtab/classfile/ClassfileParser.scala | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/sources/scala/tools/nsc/symtab/classfile/ClassfileParser.scala b/sources/scala/tools/nsc/symtab/classfile/ClassfileParser.scala index 3531115583..2379d09400 100755 --- a/sources/scala/tools/nsc/symtab/classfile/ClassfileParser.scala +++ b/sources/scala/tools/nsc/symtab/classfile/ClassfileParser.scala @@ -18,7 +18,7 @@ abstract class ClassfileParser { private var in: AbstractFileReader = _; // the class file private var clazz: Symbol = _; // the class symbol containing dynamic members - private var statics: Symbol = _; // the module class symbol containing static members + private var staticModule: Symbol = _; // the module symbol containing static members private var instanceDefs: Scope = _; // the scope of all instance definitions private var staticDefs: Scope = _; // the scope of all static definitions private var pool: ConstantPool = _; // the classfile's constant pool @@ -40,10 +40,10 @@ abstract class ClassfileParser { this.in = new AbstractFileReader(file); if (root.isModule) { this.clazz = root.linkedClass; - this.statics = root.moduleClass + this.staticModule = root } else { this.clazz = root; - this.statics = root.linkedModule.moduleClass; + this.staticModule = root.linkedModule } this.isScala = false; this.hasMeta = false; @@ -59,6 +59,8 @@ abstract class ClassfileParser { busy = false } + private def statics: Symbol = staticModule.moduleClass; + private def parseHeader: unit = { val magic = in.nextInt(); if (magic != JAVA_MAGIC) @@ -239,7 +241,7 @@ abstract class ClassfileParser { clazz.setInfo(classInfo); statics.setInfo(staticInfo); } - statics.sourceModule.setInfo(statics.tpe); + staticModule.setInfo(statics.tpe); in.bp = curbp; val fieldCount = in.nextChar(); for (val i <- Iterator.range(0, fieldCount)) parseField(); |