Commit ec7fcfdd authored by Joachim Breitner's avatar Joachim Breitner
Browse files

Degrade "case scrutinee not known to diverge for sure" Lint error to warning

as proposed in #12435, as it easily gets in the way of development when
it reports false positives.
parent d6fd2e37
......@@ -715,7 +715,7 @@ lintCoreExpr e@(Case scrut var alt_ty alts) =
; when (null alts) $
do { checkL (not (exprIsHNF scrut))
(text "No alternatives for a case scrutinee in head-normal form:" <+> ppr scrut)
; checkL scrut_diverges
; checkWarnL scrut_diverges
(text "No alternatives for a case scrutinee not known to diverge for sure:" <+> ppr scrut)
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment