- Sort Score
- Result 10 results
- Languages All
Results 1 - 1 of 1 for TestLeadingZeros (0.3 sec)
-
src/math/bits/bits_test.go
"testing" "unsafe" ) func TestUintSize(t *testing.T) { var x uint if want := unsafe.Sizeof(x) * 8; UintSize != want { t.Fatalf("UintSize = %d; want %d", UintSize, want) } } func TestLeadingZeros(t *testing.T) { for i := 0; i < 256; i++ { nlz := tab[i].nlz for k := 0; k < 64-8; k++ { x := uint64(i) << uint(k) if x <= 1<<8-1 { got := LeadingZeros8(uint8(x)) want := nlz - k + (8 - 8)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Apr 22 20:11:06 UTC 2020 - 32.5K bytes - Viewed (0)