Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a4867ae
commit 5215153
Showing
2 changed files
with
12 additions
and
2 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
linter-settings: | ||
reassign: | ||
patterns: | ||
- EOF | ||
- DefaultClient |
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,8 +1,13 @@ | ||
//golangcitest:args -Ereassign | ||
//golangcitest:config_path testdata/configs/reassign.yml | ||
package testdata | ||
|
||
import "io" | ||
import ( | ||
"io" | ||
"net/http" | ||
) | ||
|
||
func breakIO() { | ||
io.EOF = nil // ERROR `reassigning variable EOF in other package io` | ||
http.DefaultClient = nil // ERROR `reassigning variable DefaultClient in other package http` | ||
io.EOF = nil // ERROR `reassigning variable EOF in other package io` | ||
} |