Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
checkers: add skip experimental tag by default for user defined rules (…
- Loading branch information
Showing
8 changed files
with
32 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
exit status 1 | ||
./f1.go:5:1: ruleguard: error as an underlying type is probably a mistake | ||
./f1.go:9:10: ruleguard: suggestion: s1+s2 | ||
./f1.go:25:6: ruleguard: use errors.New(k()) or fmt.Errorf("%s", k()) instead | ||
./f1.go:8:1: ruleguard: error as an underlying type is probably a mistake | ||
./f1.go:12:36: ruleguard: suggestion: s1+s2 | ||
./f1.go:29:6: ruleguard: use errors.New(k()) or fmt.Errorf("%s", k()) instead |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
exit status 1 | ||
./f1.go:25:6: ruleguard: use errors.New(k()) or fmt.Errorf("%s", k()) instead | ||
./f1.go:29:6: ruleguard: use errors.New(k()) or fmt.Errorf("%s", k()) instead |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
exit status 1 | ||
./f1.go:14:2: ruleguard: may be simplified to one if | ||
./f1.go:25:6: ruleguard: use errors.New(k()) or fmt.Errorf("%s", k()) instead | ||
./f1.go:18:2: ruleguard: may be simplified to one if | ||
./f1.go:12:10: ruleguard: regexp compilation should be avoided on the hot paths | ||
./f1.go:29:6: ruleguard: use errors.New(k()) or fmt.Errorf("%s", k()) instead |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
exit status 1 | ||
./f1.go:8:1: ruleguard: error as an underlying type is probably a mistake | ||
./f1.go:18:2: ruleguard: may be simplified to one if | ||
./f1.go:12:36: ruleguard: suggestion: s1+s2 | ||
./f1.go:29:6: ruleguard: use errors.New(k()) or fmt.Errorf("%s", k()) instead |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
check -@ruleguard.rules ./rules.go -enable ruleguard -@ruleguard.disable=#test ./... | linttest.golden | ||
check -@ruleguard.rules ./rules.go -enable ruleguard -@ruleguard.enable=#style -@ruleguard.disable=#test ./... | linttest.golden2 | ||
check -@ruleguard.rules ./rules.go -enable ruleguard -@ruleguard.enable=#style,#test ./... | linttest.golden3 | ||
check -@ruleguard.rules ./rules.go -enable ruleguard -@ruleguard.enable=#style,#test,#experimental ./... | linttest.golden3 | ||
check -@ruleguard.rules ./rules.go -enable ruleguard ./... | linttest.golden4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters