- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 461 for shifts9 (3.55 sec)
-
src/internal/types/testdata/check/shifts.go
} func shifts8() { // shift examples from shift discussion: better error messages var s uint _ = 1.0 /* ERROR "shifted operand 1.0 (type float64) must be integer" */ <<s == 1 _ = 1.0 /* ERROR "shifted operand 1.0 (type float64) must be integer" */ <<s == 1.0 _ = 1 /* ERROR "shifted operand 1 (type float64) must be integer" */ <<s == 1.0
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Jan 17 19:54:27 UTC 2023 - 12.7K bytes - Viewed (0) -
src/go/types/testdata/local/shifts.go
// Copyright 2022 The Go Authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. // The following shift tests are disabled in the shared // testdata/check/shifts.go file because they don't work // correctly with types2 at the moment. See go.dev/issue/52080. // Make sure we keep testing them with go/types. // // TODO(gri) Once go.dev/issue/52080 is fixed, this file can be
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Feb 01 21:31:01 UTC 2023 - 886 bytes - Viewed (0) -
test/shift1.go
_ = 1<<s == 1. // ERROR "invalid|shift of type float64" _ = 1.<<s == 1 // ERROR "invalid|shift of type float64" _ = 1.<<s == 1. // ERROR "invalid|non-integer|shift of type float64" _ = 1<<s+1 == 1 _ = 1<<s+1 == 1. // ERROR "invalid|shift of type float64" _ = 1<<s+1. == 1 // ERROR "invalid|shift of type float64" _ = 1<<s+1. == 1. // ERROR "invalid|shift of type float64" _ = 1.<<s+1 == 1 // ERROR "invalid|shift of type float64"
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Dec 03 16:24:32 UTC 2021 - 9.4K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/go/analysis/passes/shift/shift.go
} } }) return nil, nil } // checkLongShift checks if shift or shift-assign operations shift by more than // the length of the underlying variable. func checkLongShift(pass *analysis.Pass, node ast.Node, x, y ast.Expr) { if pass.TypesInfo.Types[x].Value != nil { // Ignore shifts of constants. // These are frequently used for bit-twiddling tricks
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 02 02:20:05 UTC 2024 - 3.5K bytes - Viewed (0) -
test/shift2.go
m int = 1.0 << s // legal: 1.0 has type int w int64 = 1.0 << 33 // legal: 1.0<<33 is a constant shift expression ) // non-constant shift expressions var ( a1 int = 2.0 << s // typeof(2.0) is int in this context => legal shift d1 = f(2.0 << s) // typeof(2.0) is int in this context => legal shift ) // constant shift expressions const c uint = 5 var ( a2 int = 2.0 << c // a2 == 64 (type int)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 02 13:43:18 UTC 2016 - 1.3K bytes - Viewed (0) -
src/cmd/compile/internal/ssa/memcombine.go
} } // Check for reads in little-endian or big-endian order. shift0 := r[0].shift isLittleEndian := true for i := int64(0); i < n; i++ { if r[i].shift != shift0+i*size*8 { isLittleEndian = false break } } isBigEndian := true for i := int64(0); i < n; i++ { if r[i].shift != shift0-i*size*8 { isBigEndian = false break } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 21 19:45:41 UTC 2024 - 18.4K bytes - Viewed (0) -
test/shift3.go
f(x<<(1<<x), 4) f(x<<(1.<<x), 4) f(x<<((1+0i)<<x), 4) f(x<<(0i<<x), 1) // corner cases const M = math.MaxUint f(x<<(M+0), 0) // shift by untyped int representable as uint f(x<<(M+0.), 0) // shift by untyped float representable as uint f(x<<(M+0.+0i), 0) // shift by untyped complex representable as uint
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Apr 07 17:19:55 UTC 2022 - 834 bytes - Viewed (0) -
src/cmd/vet/testdata/shift/shift.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Feb 20 15:46:42 UTC 2019 - 358 bytes - Viewed (0) -
src/math/fma.go
sign = uint32(b >> 63) exp = int32(b>>52) & mask mantissa = b & fracMask if exp == 0 { // Normalize value if subnormal. shift := uint(bits.LeadingZeros64(mantissa) - 11) mantissa <<= shift exp = 1 - int32(shift) } else { // Add implicit 1 bit mantissa |= 1 << 52 } return } // FMA returns x * y + z, computed with only one rounding.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Jul 05 22:05:30 UTC 2023 - 4.6K bytes - Viewed (0) -
src/compress/flate/testdata/huffman-shifts.in
Klaus Post <******@****.***> 1457448890 +0100
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Mar 11 17:40:52 UTC 2016 - 6.4K bytes - Viewed (0)