Fix error by linter

This commit is contained in:
Masaaki Goshima 2021-02-09 22:24:53 +09:00
parent 98de7ff51b
commit a57bc23adf
1 changed files with 6 additions and 9 deletions

View File

@ -12,14 +12,12 @@ const (
) )
var ( var (
cachedOpcodeSets []*opcodeSet cachedOpcodeSets []*opcodeSet
cachedOpcodeMap unsafe.Pointer // map[uintptr]*opcodeSet cachedOpcodeMap unsafe.Pointer // map[uintptr]*opcodeSet
existsCachedOpcodeSets bool cachedDecoder []decoder
cachedDecoder []decoder cachedDecoderMap unsafe.Pointer // map[uintptr]decoder
cachedDecoderMap unsafe.Pointer // map[uintptr]decoder baseTypeAddr uintptr
existsCachedDecoder bool maxTypeAddr uintptr
baseTypeAddr uintptr
maxTypeAddr uintptr
) )
//go:linkname typelinks reflect.typelinks //go:linkname typelinks reflect.typelinks
@ -69,7 +67,6 @@ func setupCodec() error {
return fmt.Errorf("too big address range %d", addrRange) return fmt.Errorf("too big address range %d", addrRange)
} }
cachedOpcodeSets = make([]*opcodeSet, addrRange) cachedOpcodeSets = make([]*opcodeSet, addrRange)
existsCachedOpcodeSets = true
cachedDecoder = make([]decoder, addrRange) cachedDecoder = make([]decoder, addrRange)
baseTypeAddr = min baseTypeAddr = min
maxTypeAddr = max maxTypeAddr = max