Revamp analyzer diagnostic system
Opened this issue · 5 comments
Our analyzer currently works this way:
- recommended rules emit a diagnostic error
- non-recommended rules don't emit any diagnostic
This behaviour is different from the majority of linters/analyzers out there, and it's really confusing for people who use other tools. We intended to change it, so:
- lint rules will always have a severity (it will be
Severity::Information
by default) - recommended rules won't change the severity of a rule
This means there could be lint rules that will have Severity::Warning
rules and be recommended.
Are there some rationales for using Severity::Information
by default instead of Severity::Warning
?
There are no particular rationales, feel free to propose something in here. Severity::Information
is the Default
implementation of Severity
Maybe we should use the default implementation of Severity that should be Severity::Off
?
That's a variant that doesn't exist in Severity
. It's possible there's some misunderstanding, so instead of talking code, why don't you propose a "business logic" instead?
Indeed, I had some understanding. Looks good to me.