quickfix: add severities to all checks
@@ -6,11 +6,15 @@ var Docs = lint.Markdownify(map[string]*lint.Documentation{
"QF1000": {
Title: "Use byte-specific indexing function",
Since: "Unreleased",
+ Severity: lint.SeverityHint,
},
+
"QF1001": {
Title: "Apply De Morgan's law",
Since: "Unreleased",
+ Severity: lint.SeverityHint,
},
+
"QF1002": {
Title: "Convert untagged switch to tagged switch",
Text: `An untagged switch that compares a single variable against a series of values can be replaced with a tagged switch.
@@ -38,7 +42,9 @@ After:
}
`,
Since: "Unreleased",
+ Severity: lint.SeverityHint,
},
+
"QF1003": {
Title: "Convert if/else-if chain to tagged switch",
Text: `A series of if/else-if checks comparing the same variable against values can be replaced with a tagged switch.
@@ -64,10 +70,14 @@ After:
...
}`,
Since: "Unreleased",
+ Severity: lint.SeverityHint,
},
+
"QF1004": {
Since: "Unreleased",
+ Severity: lint.SeverityHint,
},
+
"QF1005": {
Title: "Expand call to `math.Pow`",
Text: `Some uses of \'math.Pow\' can be simplified to basic multiplication.
@@ -80,6 +90,7 @@ After:
x * x`,
Since: "Unreleased",
+ Severity: lint.SeverityHint,
},
"QF1006": {
@@ -99,6 +110,7 @@ After:
...
}`,
Since: "Unreleased",
+ Severity: lint.SeverityHint,
},
"QF1007": {
@@ -115,20 +127,24 @@ After:
x := someCondition
`,
Since: "Unreleased",
+ Severity: lint.SeverityHint,
},
"QF1008": {
Title: "Omit embedded fields from selector expression",
Since: "Unreleased",
+ Severity: lint.SeverityHint,
},
"QF1009": {
Title: `Use time.Time.Equal instead of \'==\' operator`,
Since: "Unreleased",
+ Severity: lint.SeverityHint,
},
"QF1010": {
Title: "Convert slice of bytes to string when printing it",
Since: "Unreleased",
+ Severity: lint.SeverityHint,
},
})
