Skip to content

Commit 92c6c88

Browse files
committed
Restore unsafe-warn-patvars
1 parent aa9db1f commit 92c6c88

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

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

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -184,9 +184,10 @@ private sealed trait WarningSettings:
184184
ChoiceWithHelp("linted", "Enable -Wunused:imports,privates,locals,implicits"),
185185
ChoiceWithHelp(
186186
name = "strict-no-implicit-warn",
187-
description = "Same as -Wunused:import, only for imports of explicit named members.\n" +
188-
"NOTE : This overrides -Wunused:imports and NOT set by -Wunused:all"
187+
description = """Same as -Wunused:imports, only for imports of explicit named members.
188+
|NOTE : This overrides -Wunused:imports and NOT set by -Wunused:all""".stripMargin
189189
),
190+
ChoiceWithHelp("unsafe-warn-patvars", "Deprecated alias for `patvars`"),
190191
),
191192
default = Nil
192193
)
@@ -211,7 +212,7 @@ private sealed trait WarningSettings:
211212
def params(using Context) = allOr("params")
212213
def privates(using Context) =
213214
allOr("privates") || allOr("linted")
214-
def patvars(using Context) = allOr("patvars")
215+
def patvars(using Context) = allOr("patvars") || isChoiceSet("unsafe-warn-patvars")
215216
def inlined(using Context) = isChoiceSet("inlined")
216217
def linted(using Context) =
217218
allOr("linted")

0 commit comments

Comments
 (0)