File tree Expand file tree Collapse file tree 3 files changed +22
-2
lines changed Expand file tree Collapse file tree 3 files changed +22
-2
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,11 @@ var DefaultExcludedSymbols = []string{
47
47
48
48
// hash
49
49
"(hash.Hash).Write" ,
50
+
51
+ // hash/maphash
52
+ "(*hash/maphash.Hash).Write" ,
53
+ "(*hash/maphash.Hash).WriteByte" ,
54
+ "(*hash/maphash.Hash).WriteString" ,
50
55
}
51
56
52
57
// ReadExcludes reads an excludes file, a newline delimited file that lists
Original file line number Diff line number Diff line change
1
+ package main
2
+
3
+ import (
4
+ "crypto/sha256"
5
+ "hash/maphash"
6
+ )
7
+
8
+ func ignoreHashReturns () {
9
+ sha256 .New ().Write ([]byte {}) // EXCLUDED
10
+ }
11
+
12
+ func ignoreHashMapReturns () {
13
+ var hasher maphash.Hash
14
+ hasher .Write (nil ) // EXCLUDED
15
+ hasher .WriteByte (0 ) // EXCLUDED
16
+ hasher .WriteString ("" ) // EXCLUDED
17
+ }
Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ package main
2
2
3
3
import (
4
4
"bytes"
5
- "crypto/sha256"
6
5
"fmt"
7
6
"io"
8
7
"math/rand"
@@ -147,7 +146,6 @@ func main() {
147
146
b2 .Write (nil )
148
147
rand .Read (nil )
149
148
mrand .Read (nil )
150
- sha256 .New ().Write ([]byte {})
151
149
pr , pw := io .Pipe ()
152
150
pr .CloseWithError (nil )
153
151
pw .CloseWithError (nil )
You can’t perform that action at this time.
0 commit comments