Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for MapMaxKeyBytes (0.26 sec)

  1. src/runtime/map.go

    	// Check invariants and reflects math.
    	if t.Key.Equal == nil {
    		throw("runtime.reflect_makemap: unsupported map key type")
    	}
    	if t.Key.Size_ > abi.MapMaxKeyBytes && (!t.IndirectKey() || t.KeySize != uint8(goarch.PtrSize)) ||
    		t.Key.Size_ <= abi.MapMaxKeyBytes && (t.IndirectKey() || t.KeySize != uint8(t.Key.Size_)) {
    		throw("key size wrong")
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 17:58:53 UTC 2024
    - 57.6K bytes
    - Viewed (0)
  2. src/reflect/type.go

    	mt.Key = ktyp
    	mt.Elem = etyp
    	mt.Bucket = bucketOf(ktyp, etyp)
    	mt.Hasher = func(p unsafe.Pointer, seed uintptr) uintptr {
    		return typehash(ktyp, p, seed)
    	}
    	mt.Flags = 0
    	if ktyp.Size_ > abi.MapMaxKeyBytes {
    		mt.KeySize = uint8(goarch.PtrSize)
    		mt.Flags |= 1 // indirect key
    	} else {
    		mt.KeySize = uint8(ktyp.Size_)
    	}
    	if etyp.Size_ > abi.MapMaxElemBytes {
    		mt.ValueSize = uint8(goarch.PtrSize)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 17:58:53 UTC 2024
    - 85.5K bytes
    - Viewed (0)
Back to top