- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 402 for SLICE (0.04 sec)
-
src/go/types/conversions.go
return true } // "and vice versa" if isUnsafePointer(Vu) && (isPointer(Tu) || isUintptr(Tu)) { return true } // "V is a slice, T is an array or pointer-to-array type, // and the slice and array types have identical element types." if s, _ := Vu.(*Slice); s != nil { switch a := Tu.(type) { case *Array: if Identical(s.Elem(), a.Elem()) { if check == nil || check.allowVersion(x, go1_20) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 22 18:51:00 UTC 2024 - 9.1K bytes - Viewed (0) -
src/go/types/subst.go
} case *Array: elem := subst.typOrNil(t.elem) if elem != t.elem { return &Array{len: t.len, elem: elem} } case *Slice: elem := subst.typOrNil(t.elem) if elem != t.elem { return &Slice{elem: elem} } case *Struct: if fields, copied := subst.varList(t.fields); copied { s := &Struct{fields: fields, tags: t.tags} s.markComplete() return s
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:04:07 UTC 2024 - 11.1K bytes - Viewed (0) -
src/internal/types/testdata/check/builtins0.go
} func Slice1() { var x int unsafe.Slice() // ERROR "not enough arguments" unsafe.Slice(1, 2, 3) // ERROR "too many arguments" unsafe.Slice(1 /* ERROR "is not a pointer" */ , 2) unsafe.Slice(nil /* ERROR "nil is not a pointer" */ , 0) unsafe.Slice(&x, "foo" /* ERRORx `cannot convert .* to type int` */ ) unsafe.Slice(&x, 1.2 /* ERROR "truncated to int" */ ) unsafe.Slice(&x, - /* ERROR "must not be negative" */ 1)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 29.3K bytes - Viewed (0) -
src/cmd/compile/internal/types2/subst.go
} case *Array: elem := subst.typOrNil(t.elem) if elem != t.elem { return &Array{len: t.len, elem: elem} } case *Slice: elem := subst.typOrNil(t.elem) if elem != t.elem { return &Slice{elem: elem} } case *Struct: if fields, copied := subst.varList(t.fields); copied { s := &Struct{fields: fields, tags: t.tags} s.markComplete() return s
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:04:07 UTC 2024 - 11K bytes - Viewed (0) -
src/reflect/iter.go
// If v's kind is Pointer, the pointer element type must have kind Array. // Otherwise v's kind must be Int, Int8, Int16, Int32, Int64, // Uint, Uint8, Uint16, Uint32, Uint64, Uintptr, // Array, Chan, Map, Slice, or String. func (v Value) Seq() iter.Seq[Value] { if canRangeFunc(v.typ()) { return func(yield func(Value) bool) { rf := MakeFunc(v.Type().In(0), func(in []Value) []Value { return []Value{ValueOf(yield(in[0]))}
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 22 13:40:11 UTC 2024 - 3.9K bytes - Viewed (0) -
src/cmd/compile/internal/types2/conversions.go
return true } // "and vice versa" if isUnsafePointer(Vu) && (isPointer(Tu) || isUintptr(Tu)) { return true } // "V is a slice, T is an array or pointer-to-array type, // and the slice and array types have identical element types." if s, _ := Vu.(*Slice); s != nil { switch a := Tu.(type) { case *Array: if Identical(s.Elem(), a.Elem()) { if check == nil || check.allowVersion(x, go1_20) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 22 18:51:00 UTC 2024 - 9K bytes - Viewed (0) -
src/cmd/compile/internal/types2/builtins.go
} case _SliceData: // unsafe.SliceData(slice []T) *T check.verifyVersionf(call.Fun, go1_20, "unsafe.SliceData") slice, _ := coreType(x.typ).(*Slice) if slice == nil { check.errorf(x, InvalidUnsafeSliceData, invalidArg+"%s is not a slice", x) return } x.mode = value x.typ = NewPointer(slice.elem) if check.recordTypes() {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 27.1K bytes - Viewed (0) -
src/index/suffixarray/suffixarray.go
} else { // re-use existing buffers x.data = x.data[0:n] x.sa = x.sa.slice(0, n) } // read data if _, err := io.ReadFull(r, x.data); err != nil { return err } // read index sa := x.sa for sa.len() > 0 { n, err := readSlice(r, buf, sa) if err != nil { return err } sa = sa.slice(n, sa.len()) } return nil } // Write writes the index x to w.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 9.5K bytes - Viewed (0) -
src/cmd/trace/gstate.go
panic("non-executing goroutine stopped") } ctx.Slice(traceviewer.SliceEvent{ Name: gs.name(), Ts: ctx.elapsed(gs.startRunningTime), Dur: ts.Sub(gs.startRunningTime), Resource: uint64(gs.executing), Stack: stk, }) // Flush completed ranges. for _, cr := range gs.completedRanges { ctx.Slice(traceviewer.SliceEvent{ Name: cr.name,
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 17 18:48:18 UTC 2024 - 11.9K bytes - Viewed (0) -
src/crypto/tls/key_agreement.go
if sigType == signatureEd25519 { var signed []byte for _, slice := range slices { signed = append(signed, slice...) } return signed } if version >= VersionTLS12 { h := hashFunc.New() for _, slice := range slices { h.Write(slice) } digest := h.Sum(nil) return digest } if sigType == signatureECDSA { return sha1Hash(slices)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 22 14:56:25 UTC 2024 - 11.8K bytes - Viewed (0)