Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 36 for slicelit (0.21 sec)

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

    	case ir.OSTR2BYTESTMP:
    		n := n.(*ir.ConvExpr)
    		return walkStringToBytesTemp(n, init)
    
    	case ir.OSTR2RUNES:
    		n := n.(*ir.ConvExpr)
    		return walkStringToRunes(n, init)
    
    	case ir.OARRAYLIT, ir.OSLICELIT, ir.OMAPLIT, ir.OSTRUCTLIT, ir.OPTRLIT:
    		return walkCompLit(n, init)
    
    	case ir.OSEND:
    		n := n.(*ir.SendStmt)
    		return walkSend(n, init)
    
    	case ir.OCLOSURE:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 04 17:34:01 UTC 2024
    - 27.6K bytes
    - Viewed (0)
  2. src/encoding/gob/decode.go

    			elemOp := dec.decIgnoreOpFor(elemId, inProgress, depth+1)
    			op = func(i *decInstr, state *decoderState, value reflect.Value) {
    				state.dec.ignoreMap(state, *keyOp, *elemOp)
    			}
    
    		case wire.SliceT != nil:
    			elemId := wire.SliceT.Elem
    			elemOp := dec.decIgnoreOpFor(elemId, inProgress, depth+1)
    			op = func(i *decInstr, state *decoderState, value reflect.Value) {
    				state.dec.ignoreSlice(state, *elemOp)
    			}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Sep 07 19:10:23 UTC 2023
    - 40.1K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/ssa/rewritedec.go

    	v_0 := v.Args[0]
    	b := v.Block
    	config := b.Func.Config
    	typ := &b.Func.Config.Types
    	// match: (SliceLen (SliceMake _ len _))
    	// result: len
    	for {
    		if v_0.Op != OpSliceMake {
    			break
    		}
    		len := v_0.Args[1]
    		v.copyOf(len)
    		return true
    	}
    	// match: (SliceLen x:(Load <t> ptr mem))
    	// cond: t.IsSlice()
    	// result: @x.Block (Load <typ.Int> (OffPtr <typ.IntPtr> [config.PtrSize] ptr) mem)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 12 00:48:31 UTC 2023
    - 24.9K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/ssa/_gen/generic.rules

    // a more comprehensive set.
    (SliceLen (SliceMake _ (Const64 <t> [c]) _)) => (Const64 <t> [c])
    (SliceCap (SliceMake _ _ (Const64 <t> [c]))) => (Const64 <t> [c])
    (SliceLen (SliceMake _ (Const32 <t> [c]) _)) => (Const32 <t> [c])
    (SliceCap (SliceMake _ _ (Const32 <t> [c]))) => (Const32 <t> [c])
    (SlicePtr (SliceMake (SlicePtr x) _ _)) => (SlicePtr x)
    (SliceLen (SliceMake _ (SliceLen x) _)) => (SliceLen x)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 16 22:21:05 UTC 2024
    - 135.3K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/typecheck/stmt.go

    			// TODO(mdempsky): Limit to static callees with
    			// //go:uintptr{escapes,keepalive}?
    			if arg.Type().IsUintptr() && arg.X.Type().IsUnsafePtr() {
    				visit(&arg.X)
    				return
    			}
    
    		case ir.OARRAYLIT, ir.OSLICELIT, ir.OSTRUCTLIT:
    			// TODO(mdempsky): For very large slices, it may be preferable
    			// to construct them at the go/defer statement instead.
    			list := arg.(*ir.CompLitExpr).List
    			for i, el := range list {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Nov 20 15:10:54 UTC 2023
    - 17.8K bytes
    - Viewed (0)
  6. src/cmd/compile/internal/typecheck/expr.go

    	case types.TARRAY:
    		typecheckarraylit(t.Elem(), t.NumElem(), n.List, "array literal")
    		n.SetOp(ir.OARRAYLIT)
    
    	case types.TSLICE:
    		length := typecheckarraylit(t.Elem(), -1, n.List, "slice literal")
    		n.SetOp(ir.OSLICELIT)
    		n.Len = length
    
    	case types.TMAP:
    		for i3, l := range n.List {
    			ir.SetPos(l)
    			if l.Op() != ir.OKEY {
    				n.List[i3] = Expr(l)
    				base.Errorf("missing key in map literal")
    				continue
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 04 14:29:45 UTC 2024
    - 23.1K bytes
    - Viewed (0)
  7. src/encoding/gob/doc.go

    pair (-type id, encoded-type) where encoded-type is the gob encoding of a wireType
    description, constructed from these types:
    
    	type wireType struct {
    		ArrayT           *ArrayType
    		SliceT           *SliceType
    		StructT          *StructType
    		MapT             *MapType
    		GobEncoderT      *gobEncoderType
    		BinaryMarshalerT *gobEncoderType
    		TextMarshalerT   *gobEncoderType
    
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 11 20:22:45 UTC 2024
    - 17.1K bytes
    - Viewed (0)
  8. src/reflect/all_test.go

    	}
    
    	typ = TypeOf(0)
    	if !SliceAt(typ, unsafe.Pointer((*int)(nil)), 0).IsNil() {
    		t.Fatal("nil pointer with zero length must return nil")
    	}
    
    	// nil pointer with positive length panics
    	shouldPanic("", func() { _ = SliceAt(typ, unsafe.Pointer((*int)(nil)), 1) })
    
    	// negative length
    	var neg int = -1
    	shouldPanic("", func() { _ = SliceAt(TypeOf(byte(0)), unsafe.Pointer(&p[0]), neg) })
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 218.8K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/walk/order.go

    		n := n.(*ir.SelectorExpr)
    		n.X = o.expr(n.X, nil)
    		if n.Transient() {
    			t := typecheck.MethodValueType(n)
    			n.Prealloc = o.newTemp(t, false)
    		}
    		return n
    
    	case ir.OSLICELIT:
    		n := n.(*ir.CompLitExpr)
    		o.exprList(n.List)
    		if n.Transient() {
    			t := types.NewArray(n.Type().Elem(), n.Len)
    			n.Prealloc = o.newTemp(t, false)
    		}
    		return n
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 08 02:00:33 UTC 2024
    - 42.7K bytes
    - Viewed (0)
  10. src/cmd/compile/internal/ssa/_gen/genericOps.go

    	// Slices
    	{name: "SliceMake", argLength: 3},                // arg0=ptr, arg1=len, arg2=cap
    	{name: "SlicePtr", argLength: 1, typ: "BytePtr"}, // ptr(arg0)
    	{name: "SliceLen", argLength: 1},                 // len(arg0)
    	{name: "SliceCap", argLength: 1},                 // cap(arg0)
    	// SlicePtrUnchecked, like SlicePtr, extracts the pointer from a slice.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 15:49:20 UTC 2024
    - 42.6K bytes
    - Viewed (0)
Back to top