File tree 2 files changed +15
-3
lines changed
2 files changed +15
-3
lines changed Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ bootcp=true
32
32
33
33
CompilerMain=dotty.tools.dotc.Main
34
34
FromTasty=dotty.tools.dotc.FromTasty
35
- ReplMain=dotty.tools.dotc. repl.Main
35
+ ReplMain=dotty.tools.repl.Main
36
36
37
37
PROG_NAME=$CompilerMain
38
38
Original file line number Diff line number Diff line change @@ -391,8 +391,6 @@ object Build {
391
391
)
392
392
}.evaluated,
393
393
394
- repl := run.evaluated,
395
-
396
394
javaOptions ++= (javaOptions in `dotty-compiler`).value,
397
395
fork in run := true ,
398
396
fork in Test := true ,
@@ -581,6 +579,20 @@ object Build {
581
579
}.evaluated,
582
580
dotc := run.evaluated,
583
581
582
+ repl := Def .inputTaskDyn {
583
+ val dottyLib = packageAll.value(" dotty-library" )
584
+ val args : Seq [String ] = spaceDelimited(" <arg>" ).parsed
585
+
586
+ val fullArgs = args.span(_ != " -classpath" ) match {
587
+ case (beforeCp, Nil ) => beforeCp ++ (" -classpath" :: dottyLib :: Nil )
588
+ case (beforeCp, rest) => beforeCp ++ rest
589
+ }
590
+
591
+ (runMain in Compile ).toTask(
592
+ s " dotty.tools.repl.Main " + fullArgs.mkString(" " )
593
+ )
594
+ }.evaluated,
595
+
584
596
// enable verbose exception messages for JUnit
585
597
testOptions in Test += Tests .Argument (
586
598
TestFrameworks .JUnit , " -a" , " -v" ,
You can’t perform that action at this time.
0 commit comments