Search Options

Results per page
Sort
Preferred Languages
Advance

Results 61 - 70 of 93 for maxInt (0.28 sec)

  1. staging/src/k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/validation/validation_test.go

    		},
    		{
    			name: "integer overflow bounds check",
    			schema: []*apiextensions.JSONSchemaProps{
    				withMaxItems(genArraySchema(), int64ptr(math.MaxInt)),
    				withMaxItems(genArraySchema(), int64ptr(100)),
    			},
    			expectedMaxCardinality: uint64ptr(math.MaxUint),
    		},
    	}
    	for _, tt := range tests {
    		t.Run(tt.name, func(t *testing.T) {
    			// simulate the recursive validation calls
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 10 22:07:40 UTC 2024
    - 349.4K bytes
    - Viewed (0)
  2. src/math/big/floatconv.go

    	}
    
    	// mantissa
    	var fcount int // fractional digit count; valid if <= 0
    	z.mant, b, fcount, err = z.mant.scan(r, base, true)
    	if err != nil {
    		return
    	}
    
    	// exponent
    	var exp int64
    	var ebase int
    	exp, ebase, err = scanExponent(r, true, base == 0)
    	if err != nil {
    		return
    	}
    
    	// special-case 0
    	if len(z.mant) == 0 {
    		z.prec = prec
    		z.acc = Exact
    		z.form = zero
    		f = z
    		return
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 11:59:09 UTC 2023
    - 8.3K bytes
    - Viewed (0)
  3. src/strconv/atof.go

    	d.Shift(int(1 + flt.mantbits))
    	mant = d.RoundedInteger()
    
    	// Rounding might have added a bit; shift down.
    	if mant == 2<<flt.mantbits {
    		mant >>= 1
    		exp++
    		if exp-flt.bias >= 1<<flt.expbits-1 {
    			goto overflow
    		}
    	}
    
    	// Denormalized?
    	if mant&(1<<flt.mantbits) == 0 {
    		exp = flt.bias
    	}
    	goto out
    
    overflow:
    	// ±Inf
    	mant = 0
    	exp = 1<<flt.expbits - 1 + flt.bias
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 06 18:50:50 UTC 2022
    - 15.9K bytes
    - Viewed (0)
  4. src/math/big/sqrt.go

    	z.Mul(x, sqi)
    }
    
    // newFloat returns a new *Float with space for twice the given
    // precision.
    func newFloat(prec2 uint32) *Float {
    	z := new(Float)
    	// nat.make ensures the slice length is > 0
    	z.mant = z.mant.make(int(prec2/_W) * 2)
    	return z
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 11 16:34:30 UTC 2022
    - 2.8K bytes
    - Viewed (0)
  5. src/encoding/json/bench_test.go

    type codeNode struct {
    	Name     string      `json:"name"`
    	Kids     []*codeNode `json:"kids"`
    	CLWeight float64     `json:"cl_weight"`
    	Touches  int         `json:"touches"`
    	MinT     int64       `json:"min_t"`
    	MaxT     int64       `json:"max_t"`
    	MeanT    int64       `json:"mean_t"`
    }
    
    var codeJSON []byte
    var codeStruct codeResponse
    
    func codeInit() {
    	f, err := os.Open("testdata/code.json.gz")
    	if err != nil {
    		panic(err)
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 15:00:17 UTC 2024
    - 12.5K bytes
    - Viewed (0)
  6. staging/src/k8s.io/apimachinery/pkg/runtime/serializer/cbor/internal/modes/roundtrip_test.go

    		},
    		{
    			name: "uint16 max",
    			obj:  uint16(math.MaxUint16),
    		},
    		{
    			name: "uint16 zero",
    			obj:  uint16(0),
    		},
    		{
    			name: "int8 max",
    			obj:  int8(math.MaxInt8),
    		},
    		{
    			name: "int8 min",
    			obj:  int8(math.MinInt8),
    		},
    		{
    			name: "int8 zero",
    			obj:  int8(math.MinInt8),
    		},
    		{
    			name: "uint8 max",
    			obj:  uint8(math.MaxUint8),
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Mar 01 21:48:12 UTC 2024
    - 7.1K bytes
    - Viewed (0)
  7. android/guava-tests/test/com/google/common/math/IntMathTest.java

          }
        }
      }
    
      private static final BigInteger MAX_INT = BigInteger.valueOf(Integer.MAX_VALUE);
      private static final BigInteger MIN_INT = BigInteger.valueOf(Integer.MIN_VALUE);
    
      private static int saturatedCast(BigInteger big) {
        if (big.compareTo(MAX_INT) > 0) {
          return Integer.MAX_VALUE;
        }
        if (big.compareTo(MIN_INT) < 0) {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Feb 07 17:50:39 UTC 2024
    - 24.5K bytes
    - Viewed (0)
  8. api/go1.20.txt

    pkg math (freebsd-riscv64), const MaxInt = 9223372036854775807 #53466
    pkg math (freebsd-riscv64), const MaxUint = 18446744073709551615 #53466
    pkg math (freebsd-riscv64), const MinInt = -9223372036854775808 #53466
    pkg math (freebsd-riscv64-cgo), const MaxInt = 9223372036854775807 #53466
    pkg math (freebsd-riscv64-cgo), const MaxUint = 18446744073709551615 #53466
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Feb 17 21:23:32 UTC 2023
    - 602.6K bytes
    - Viewed (1)
  9. src/go/internal/gcimporter/iimport.go

    	io.ReadFull(&r.declReader, b)
    	x.SetBytes(b)
    	if signed && n&1 != 0 {
    		x.Neg(x)
    	}
    }
    
    func (r *importReader) mpfloat(typ *types.Basic) constant.Value {
    	var mant big.Int
    	r.mpint(&mant, typ)
    	var f big.Float
    	f.SetInt(&mant)
    	if f.Sign() != 0 {
    		f.SetMantExp(&f, int(r.int64()))
    	}
    	return constant.Make(&f)
    }
    
    func (r *importReader) ident() string {
    	return r.string()
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 19.2K bytes
    - Viewed (0)
  10. src/math/big/floatconv_test.go

    		}
    	}
    }
    
    // actualPrec returns the number of actually used mantissa bits.
    func actualPrec(x float64) uint {
    	if mant := math.Float64bits(x); x != 0 && mant&(0x7ff<<52) == 0 {
    		// x is denormalized
    		return 64 - uint(bits.LeadingZeros64(mant&(1<<52-1)))
    	}
    	return 53
    }
    
    func TestFloatText(t *testing.T) {
    	const defaultRound = ^RoundingMode(0)
    
    	for _, test := range []struct {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Dec 13 18:45:54 UTC 2021
    - 24.3K bytes
    - Viewed (0)
Back to top