summaryrefslogtreecommitdiff
path: root/src/compiler/scala/tools/nsc/symtab/classfile/Pickler.scala
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2012-01-16 07:09:07 -0800
committerPaul Phillips <paulp@improving.org>2012-01-16 13:27:08 -0800
commitbf6ce00f2146ae2c3feb5d2c8a2ed5f5d441ba3b (patch)
tree985b1dd8ea85476c73c03a09390a9d513ccc1017 /src/compiler/scala/tools/nsc/symtab/classfile/Pickler.scala
parent44d783a5eaa4e77c45c6565a70395525712ded23 (diff)
downloadscala-bf6ce00f2146ae2c3feb5d2c8a2ed5f5d441ba3b.tar.gz
scala-bf6ce00f2146ae2c3feb5d2c8a2ed5f5d441ba3b.tar.bz2
scala-bf6ce00f2146ae2c3feb5d2c8a2ed5f5d441ba3b.zip
Symbol creation followup.
Changed most symbol creations to be consistent with all the others. Opportunistically streamlined various call sites. Moved some phase-specific methods out of Symbol to somewhere more appropriate (like that phase.)
Diffstat (limited to 'src/compiler/scala/tools/nsc/symtab/classfile/Pickler.scala')
-rw-r--r--src/compiler/scala/tools/nsc/symtab/classfile/Pickler.scala7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/compiler/scala/tools/nsc/symtab/classfile/Pickler.scala b/src/compiler/scala/tools/nsc/symtab/classfile/Pickler.scala
index e7d08ef849..2eddd36db0 100644
--- a/src/compiler/scala/tools/nsc/symtab/classfile/Pickler.scala
+++ b/src/compiler/scala/tools/nsc/symtab/classfile/Pickler.scala
@@ -145,11 +145,8 @@ abstract class Pickler extends SubComponent {
val (locals, globals) = sym.children partition (_.isLocalClass)
val children =
if (locals.isEmpty) globals
- else {
- val localChildDummy = sym.newClass(sym.pos, tpnme.LOCAL_CHILD)
- localChildDummy.setInfo(ClassInfoType(List(sym.tpe), EmptyScope, localChildDummy))
- globals + localChildDummy
- }
+ else globals + sym.newClassWithInfo(tpnme.LOCAL_CHILD, List(sym.tpe), EmptyScope, pos = sym.pos)
+
putChildren(sym, children.toList sortBy (_.sealedSortName))
}
for (annot <- sym.annotations filter (ann => ann.isStatic && !ann.isErroneous) reverse)