Skip to content

Commit

Permalink
Merge pull request #8292 from som-snytt/issue/xlint-help
Browse files Browse the repository at this point in the history
More clarifying -Xlint:help
  • Loading branch information
adriaanm committed Sep 3, 2019
2 parents 074dfbe + bf99f31 commit 8c9bafd
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions src/compiler/scala/tools/nsc/settings/Warnings.scala
Original file line number Diff line number Diff line change
Expand Up @@ -91,29 +91,29 @@ trait Warnings {
class LintWarning(name: String, help: String) extends Choice(name, help)
def LintWarning(name: String, help: String) = new LintWarning(name, help)

val AdaptedArgs = LintWarning("adapted-args", "Warn if an argument list is modified to match the receiver.")
val NullaryUnit = LintWarning("nullary-unit", "Warn when nullary methods return Unit.")
val AdaptedArgs = LintWarning("adapted-args", "An argument list was modified to match the receiver.")
val NullaryUnit = LintWarning("nullary-unit", "`def f: Unit` looks like an accessor; add parens to look side-effecting.")
val Inaccessible = LintWarning("inaccessible", "Warn about inaccessible types in method signatures.")
val NullaryOverride = LintWarning("nullary-override", "Warn when non-nullary `def f()' overrides nullary `def f'.")
val InferAny = LintWarning("infer-any", "Warn when a type argument is inferred to be `Any`.")
val NullaryOverride = LintWarning("nullary-override", "Non-nullary `def f()` overrides nullary `def f`.")
val InferAny = LintWarning("infer-any", "A type argument was inferred as Any.")
val MissingInterpolator = LintWarning("missing-interpolator", "A string literal appears to be missing an interpolator id.")
val DocDetached = LintWarning("doc-detached", "A Scaladoc comment appears to be detached from its element.")
val DocDetached = LintWarning("doc-detached", "When running scaladoc, warn if a doc comment is discarded.")
val PrivateShadow = LintWarning("private-shadow", "A private field (or class parameter) shadows a superclass field.")
val TypeParameterShadow = LintWarning("type-parameter-shadow", "A local type parameter shadows a type already in scope.")
val PolyImplicitOverload = LintWarning("poly-implicit-overload", "Parameterized overloaded implicit methods are not visible as view bounds.")
val OptionImplicit = LintWarning("option-implicit", "Option.apply used implicit view.")
val OptionImplicit = LintWarning("option-implicit", "Option.apply used an implicit view.")
val DelayedInitSelect = LintWarning("delayedinit-select", "Selecting member of DelayedInit.")
val PackageObjectClasses = LintWarning("package-object-classes", "Class or object defined in package object.")
val StarsAlign = LintWarning("stars-align", "Pattern sequence wildcard must align with sequence component.")
val Constant = LintWarning("constant", "Evaluation of a constant arithmetic expression results in an error.")
val StarsAlign = LintWarning("stars-align", "In a pattern, a sequence wildcard `_*` should match all of a repeated parameter.")
val Constant = LintWarning("constant", "Evaluation of a constant arithmetic expression resulted in an error.")
val Unused = LintWarning("unused", "Enable -Wunused:imports,privates,locals,implicits.")
val NonlocalReturn = LintWarning("nonlocal-return", "A return statement used an exception for flow control.")
val ImplicitNotFound = LintWarning("implicit-not-found", "Check @implicitNotFound and @implicitAmbiguous messages.")
val Serial = LintWarning("serial", "@SerialVersionUID on traits and non-serializable classes.")
val ValPattern = LintWarning("valpattern", "Enable pattern checks in val definitions.")
val EtaZero = LintWarning("eta-zero", "Warn on eta-expansion (rather than auto-application) of zero-ary method.")
val EtaSam = LintWarning("eta-sam", "Warn on eta-expansion to meet a Java-defined functional interface that is not explicitly annotated with @FunctionalInterface.")
val Deprecation = LintWarning("deprecation", "Enable linted deprecations.")
val EtaZero = LintWarning("eta-zero", "Usage `f` of parameterless `def f()` resulted in eta-expansion, not empty application `f()`.")
val EtaSam = LintWarning("eta-sam", "The Java-defined target interface for eta-expansion was not annotated @FunctionalInterface.")
val Deprecation = LintWarning("deprecation", "Enable -deprecation and also check @deprecated annotations.")

def allLintWarnings = values.toSeq.asInstanceOf[Seq[LintWarning]]
}
Expand Down

0 comments on commit 8c9bafd

Please sign in to comment.