Search Options

Results per page
Sort
Preferred Languages
Advance

Results 131 - 140 of 947 for asSlice (0.13 sec)

  1. src/cmd/compile/internal/walk/walk.go

    		}
    
    		switch n.Op() {
    		default:
    			base.FatalfAt(n.Pos(), "mayCall %+v", n)
    
    		case ir.OCALLFUNC, ir.OCALLINTER,
    			ir.OUNSAFEADD, ir.OUNSAFESLICE:
    			return true
    
    		case ir.OINDEX, ir.OSLICE, ir.OSLICEARR, ir.OSLICE3, ir.OSLICE3ARR, ir.OSLICESTR,
    			ir.ODEREF, ir.ODOTPTR, ir.ODOTTYPE, ir.ODYNAMICDOTTYPE, ir.ODIV, ir.OMOD,
    			ir.OSLICE2ARR, ir.OSLICE2ARRPTR:
    			// These ops might panic, make sure they are done
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Feb 27 20:56:00 UTC 2024
    - 10.4K bytes
    - Viewed (0)
  2. src/slices/slices.go

    func ContainsFunc[S ~[]E, E any](s S, f func(E) bool) bool {
    	return IndexFunc(s, f) >= 0
    }
    
    // Insert inserts the values v... into s at index i,
    // returning the modified slice.
    // The elements at s[i:] are shifted up to make room.
    // In the returned slice r, r[i] == v[0],
    // and r[i+len(v)] == value originally at r[i].
    // Insert panics if i is out of range.
    // This function is O(len(s) + len(v)).
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 29 14:01:59 UTC 2024
    - 13.6K bytes
    - Viewed (0)
  3. src/cmd/vendor/golang.org/x/tools/go/ast/astutil/rewrite.go

    	i := c.Index()
    	if i < 0 {
    		panic("Delete node not contained in slice")
    	}
    	v := c.field()
    	l := v.Len()
    	reflect.Copy(v.Slice(i, l), v.Slice(i+1, l))
    	v.Index(l - 1).Set(reflect.Zero(v.Type().Elem()))
    	v.SetLen(l - 1)
    	c.iter.step--
    }
    
    // InsertAfter inserts n after the current Node in its containing slice.
    // If the current Node is not part of a slice, InsertAfter panics.
    // Apply does not walk n.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Dec 18 21:28:13 UTC 2023
    - 12.2K bytes
    - Viewed (0)
  4. staging/src/k8s.io/apiserver/pkg/authentication/request/x509/verify_options.go

    	}
    
    	return StaticVerifierFn(opts), nil
    }
    
    // StringSliceProvider is a way to get a string slice value.  It is heavily used for authentication headers among other places.
    type StringSliceProvider interface {
    	// Value returns the current string slice.  Callers should never mutate the returned value.
    	Value() []string
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Nov 07 19:48:24 UTC 2019
    - 2.2K bytes
    - Viewed (0)
  5. src/runtime/string.go

    // string and byte slice both refer to the same storage.
    // The storage is not zeroed. Callers should use
    // b to set the string contents and then drop b.
    func rawstring(size int) (s string, b []byte) {
    	p := mallocgc(uintptr(size), nil, false)
    	return unsafe.String((*byte)(p), size), unsafe.Slice((*byte)(p), size)
    }
    
    // rawbyteslice allocates a new byte slice. The byte slice is not zeroed.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:17:26 UTC 2024
    - 13.4K bytes
    - Viewed (0)
  6. tests/associations_belongs_to_test.go

    		&Company{Name: "company-slice-append-1"},
    		&Company{Name: "company-slice-append-2"},
    		&Company{Name: "company-slice-append-3"},
    	)
    
    	AssertAssociationCount(t, users, "Company", 3, "After Append")
    
    	DB.Model(&users).Association("Manager").Append(
    		GetUser("manager-slice-belongs-to-1", Config{}),
    		GetUser("manager-slice-belongs-to-2", Config{}),
    		GetUser("manager-slice-belongs-to-3", Config{}),
    	)
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Mon Oct 30 09:15:49 UTC 2023
    - 9.3K bytes
    - Viewed (0)
  7. src/go/doc/comment/testdata/doclink2.txt

    -- input --
    We use [io.Reader] a lot, and also a few map[io.Reader]string.
    
    Never [io.Reader]int or Slice[io.Reader] though.
    -- markdown --
    We use [io.Reader](/io#Reader) a lot, and also a few map\[io.Reader]string.
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 11 16:31:42 UTC 2022
    - 268 bytes
    - Viewed (0)
  8. staging/src/k8s.io/apiserver/pkg/storage/cacher/caching_object.go

    		result.raw = buffer.Bytes()
    	})
    	// Once invoked, fields of serialization will not change.
    	if result.err != nil {
    		return result.err
    	}
    	if b, support := w.(runtime.Splice); support {
    		b.Splice(result.raw)
    		return nil
    	}
    	_, err := w.Write(result.raw)
    	return err
    }
    
    // GetObject implements runtime.CacheableObject interface.
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Jun 05 18:03:48 UTC 2023
    - 12.6K bytes
    - Viewed (0)
  9. src/internal/types/testdata/check/expr3.go

    	_ = a[:10:10]
    	_ = a[:11 /* ERRORx `index .* out of bounds` */ :10]
    	_ = a[:10:11 /* ERRORx `index .* out of bounds` */ ]
    	_ = a[10:0 /* ERROR "invalid slice indices" */ :10]
    	_ = a[0:10:0 /* ERROR "invalid slice indices" */ ]
    	_ = a[10:0 /* ERROR "invalid slice indices" */:0]
    	_ = &a /* ERROR "cannot take address" */ [:10]
    
    	pa := &a
    	_ = pa[9]
    	_ = pa[10 /* ERRORx `index .* out of bounds` */ ]
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 16 22:41:49 UTC 2023
    - 15.6K bytes
    - Viewed (0)
  10. src/internal/types/testdata/check/go1_19_20.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    // Check Go language version-specific errors.
    
    //go:build go1.20
    
    package p
    
    type Slice []byte
    type Array [8]byte
    
    var s Slice
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 14 16:08:31 UTC 2023
    - 332 bytes
    - Viewed (0)
Back to top