Skip to content

Commit 5798f28

Browse files
committed
fixup
1 parent 558ceb0 commit 5798f28

File tree

2 files changed

+4
-24
lines changed

2 files changed

+4
-24
lines changed

src/compiler/scala/tools/nsc/PipelineMain.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import java.nio.file.{Files, Path, Paths}
88

99
import scala.collection.mutable
1010
import scala.reflect.internal.util.FakePos
11-
import scala.tools.nsc.reporters.Reporter
11+
import scala.tools.nsc.reporters.{ConsoleReporter, Reporter}
1212
import scala.tools.nsc.util.ClassPath
1313

1414

@@ -20,7 +20,7 @@ class PipelineMainClass {
2020

2121
private var reporter: Reporter = _
2222
def process(args: Array[String]): Boolean = {
23-
reporter = Reporter(new Settings(scalacError))
23+
reporter = new ConsoleReporter(new Settings(scalacError))
2424

2525
def commandFor(argFileArg: String): CompilerCommand = {
2626
val ss = new Settings(scalacError)

src/compiler/scala/tools/nsc/symtab/classfile/ClassfileParser.scala

Lines changed: 2 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ abstract class ClassfileParser {
175175
case None =>
176176
this.in = new AbstractFileReader(file)
177177
parseHeader()
178-
this.pool = new ConstantPool
178+
this.pool = newConstantPool
179179
parseClass()
180180
}
181181
if (isScalaRaw && !isNothingOrNull) {
@@ -479,9 +479,7 @@ abstract class ClassfileParser {
479479
n == "scala.runtime.Nothing$" || n == "scala.runtime.Null$"
480480
}
481481

482-
def parseClass(): Unit = {
483-
unpickleOrParseInnerClasses()
484-
482+
def parseClass() {
485483
val jflags = readClassFlags()
486484
val sflags = jflags.toScalaFlags
487485
val nameIdx = u2
@@ -513,24 +511,6 @@ abstract class ClassfileParser {
513511
if (!c.isInstanceOf[StubSymbol] && c != clazz) mismatchError(c)
514512
}
515513

516-
if (isScala) {
517-
() // We're done
518-
} else if (isScalaRaw && !isNothingOrNull) {
519-
val decls = clazz.enclosingPackage.info.decls
520-
for (c <- List(clazz, staticModule, staticModule.moduleClass)) {
521-
c.setInfo(NoType)
522-
decls.unlink(c)
523-
}
524-
} else {
525-
val sflags = jflags.toScalaFlags // includes JAVA
526-
527-
def parseParents(): List[Type] = raiseLoaderLevel {
528-
val superType = pool.getSuperClass(u2).tpe_*
529-
val ifaceCount = u2
530-
val ifaces = for (i <- List.range(0, ifaceCount)) yield pool.getSuperClass(u2).tpe_*
531-
superType :: ifaces
532-
}
533-
534514
addEnclosingTParams(clazz)
535515
parseInnerClasses() // also sets the isScala / isScalaRaw flags, see r15956
536516
// get the class file parser to reuse scopes.

0 commit comments

Comments
 (0)