mirror of
https://github.com/charlienet/go-mixed.git
synced 2025-07-18 08:32:40 +08:00
优化range引用
This commit is contained in:
@ -16,7 +16,9 @@ func (r BytesResult) Hex() string {
|
||||
func (r BytesResult) UppercaseHex() string {
|
||||
dst := make([]byte, hex.EncodedLen(len(r)))
|
||||
j := 0
|
||||
for _, v := range r {
|
||||
|
||||
re := r[:]
|
||||
for _, v := range re {
|
||||
dst[j] = hextable[v>>4]
|
||||
dst[j+1] = hextable[v&0x0f]
|
||||
j += 2
|
||||
|
Reference in New Issue
Block a user