Skip to content

Commit

Permalink
Merge pull request #10755 from lrytz/10704-followup
Browse files Browse the repository at this point in the history
Align WConf category for WFlagUnnamedBooleanLiteral
  • Loading branch information
SethTisue committed Apr 15, 2024
2 parents fcf69c4 + 698369d commit 83332ad
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/compiler/scala/tools/nsc/Reporting.scala
Expand Up @@ -571,7 +571,7 @@ object Reporting {
WFlagExtraImplicit,
WFlagNumericWiden,
WFlagSelfImplicit,
WFlagNamedLiteral,
WFlagUnnamedBooleanLiteral,
WFlagValueDiscard
= wflag()

Expand Down
2 changes: 1 addition & 1 deletion src/compiler/scala/tools/nsc/typechecker/RefChecks.scala
Expand Up @@ -1768,7 +1768,7 @@ abstract class RefChecks extends Transform {
case (arg, param) =>
val msg = s"Boolean literals should be passed using named argument syntax for parameter ${param.name}."
val action = runReporting.codeAction("name boolean literal", arg.pos.focusStart, s"${param.name} = ", msg)
runReporting.warning(arg.pos, msg, WarningCategory.WFlagNamedLiteral, sym, action)
runReporting.warning(arg.pos, msg, WarningCategory.WFlagUnnamedBooleanLiteral, sym, action)
case _ =>
}
}
Expand Down

0 comments on commit 83332ad

Please sign in to comment.