Skip to content

Commit 843a6b0

Browse files
committed
Deprecate the -run and -repl command line options for removal in 3.8.0
1 parent c2ff5d1 commit 843a6b0

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

compiler/src/dotty/tools/MainGenericCompiler.scala

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,8 @@ object MainGenericCompiler {
100100
case ("-q" | "-quiet") :: tail =>
101101
process(tail, settings.withQuiet)
102102
case "-repl" :: tail =>
103+
Console.err.println(s"[warning] The -repl command line option has been deprecated removal in Scala 3.8.0.")
104+
Console.err.println(s"[warning] Please use the 'scala repl' command (Scala CLI) to run the REPL.")
103105
process(tail, settings.withCompileMode(CompileMode.Repl))
104106
case "-script" :: targetScript :: tail =>
105107
process(Nil, settings
@@ -114,6 +116,8 @@ object MainGenericCompiler {
114116
case "-print-tasty" :: tail =>
115117
process(tail, settings.withCompileMode(CompileMode.PrintTasty))
116118
case "-run" :: tail =>
119+
Console.err.println(s"[warning] The -run command line option has been deprecated removal in Scala 3.8.0.")
120+
Console.err.println(s"[warning] Please use the 'scala' command (Scala CLI) instead.")
117121
process(tail, settings.withCompileMode(CompileMode.Run))
118122
case "-colors" :: tail =>
119123
process(tail, settings.withColors)

0 commit comments

Comments
 (0)