Browse Source

runtime: fix building with -tags=runtime_memhash_tsip

pull/4433/merge
Damian Gryski 2 months ago
committed by Ayke
parent
commit
fa12450552
  1. 5
      src/internal/binary/binary.go
  2. 2
      src/runtime/memhash_tsip.go

5
src/internal/binary/binary.go

@ -30,3 +30,8 @@ func (littleEndian) AppendUint16(b []byte, v uint16) []byte {
func (littleEndian) Uint32(b []byte) uint32 {
return uint32(b[0]) | uint32(b[1])<<8 | uint32(b[2])<<16 | uint32(b[3])<<24
}
func (littleEndian) Uint64(b []byte) uint64 {
return uint64(b[0]) | uint64(b[1])<<8 | uint64(b[2])<<16 | uint64(b[3])<<24 |
uint64(b[4])<<32 | uint64(b[5])<<40 | uint64(b[6])<<48 | uint64(b[7])<<56
}

2
src/runtime/memhash_tsip.go

@ -10,7 +10,7 @@
package runtime
import (
"encoding/binary"
"internal/binary"
"math/bits"
"unsafe"
)

Loading…
Cancel
Save