Skip to content

Commit 22d8622

Browse files
address PR feedback
1 parent 599438b commit 22d8622

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

compiler/src/dotty/tools/dotc/config/CompilerCommand.scala

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -116,10 +116,10 @@ object CompilerCommand {
116116
}
117117

118118
def phasesMessage: String = {
119-
(new Compiler()).phases.map(phasegroup => {
120-
if(phasegroup.length == 1) phasegroup.head.phaseName
121-
else phasegroup.mkString("{", ", ", "}")
122-
}).mkString("\n")
119+
(new Compiler()).phases.map {
120+
case List(single) => single.phaseName
121+
case more => more.map(_.phaseName).mkString("{", ", ", "}")
122+
}.mkString("\n")
123123
}
124124

125125
def infoMessage: String = {

compiler/src/dotty/tools/dotc/config/ScalaSettings.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,9 +77,9 @@ class ScalaSettings extends Settings.SettingGroup {
7777
val XprintDiff: Setting[Boolean] = BooleanSetting("-Xprint-diff", "Print changed parts of the tree since last print.")
7878
val XprintDiffDel: Setting[Boolean] = BooleanSetting("-Xprint-diff-del", "Print changed parts of the tree since last print including deleted parts.")
7979
val XprintInline: Setting[Boolean] = BooleanSetting("-Xprint-inline", "Show where inlined code comes from")
80-
val XshowPhases: Setting[Boolean] = BooleanSetting("-Xprint-phases", "Print all compiler phases")
8180
val XprintSuspension: Setting[Boolean] = BooleanSetting("-Xprint-suspension", "Show when code is suspended until macros are compiled")
8281
val Xprompt: Setting[Boolean] = BooleanSetting("-Xprompt", "Display a prompt after each error (debugging option).")
82+
val XshowPhases: Setting[Boolean] = BooleanSetting("-Xshow-phases", "Print all compiler phases")
8383
val XnoValueClasses: Setting[Boolean] = BooleanSetting("-Xno-value-classes", "Do not use value classes. Helps debugging.")
8484
val XreplLineWidth: Setting[Int] = IntSetting("-Xrepl-line-width", "Maximal number of columns per line for REPL output", 390)
8585
val XfatalWarnings: Setting[Boolean] = BooleanSetting("-Xfatal-warnings", "Fail the compilation if there are any warnings.")

0 commit comments

Comments
 (0)