We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 25b7a16 commit 1149634Copy full SHA for 1149634
src/dotty/tools/dotc/Run.scala
@@ -10,6 +10,7 @@ import reporting.Reporter
10
import transform.TreeChecker
11
import java.io.{BufferedWriter, OutputStreamWriter}
12
import scala.reflect.io.VirtualFile
13
+import scala.util.control.NonFatal
14
15
class Run(comp: Compiler)(implicit ctx: Context) {
16
@@ -27,9 +28,13 @@ class Run(comp: Compiler)(implicit ctx: Context) {
27
28
}
29
30
- def compile(fileNames: List[String]): Unit = {
31
+ def compile(fileNames: List[String]): Unit = try {
32
val sources = fileNames map getSource
33
compileSources(sources)
34
+ } catch {
35
+ case NonFatal(ex) =>
36
+ println(s"exception occurred while compiling $units%, %")
37
+ throw ex
38
39
40
/** TODO: There's a fundamental design problem here: We assmble phases using `squash`
0 commit comments