- Sort Score
- Result 10 results
- Languages All
Results 1 - 5 of 5 for SetBounded (0.54 sec)
-
src/cmd/compile/internal/walk/assign.go
nif.Cond = ir.NewBinaryExpr(base.Pos, ir.OLE, nuint, scapuint) nif.Likely = true // then { s = s[:newLen] } slice := ir.NewSliceExpr(base.Pos, ir.OSLICE, s, nil, newLen, nil) slice.SetBounded(true) nif.Body = []ir.Node{ir.NewAssignStmt(base.Pos, s, slice)} // else { s = growslice(oldPtr, newLen, oldCap, num, T) } call := walkGrowslice(s, nif.PtrInit(), oldPtr, newLen, oldCap, num)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 08 17:09:06 UTC 2024 - 20.3K bytes - Viewed (0) -
src/cmd/compile/internal/walk/walk.go
func boundedDotPtr(pos src.XPos, ptr ir.Node, field *types.Field) *ir.SelectorExpr { sel := ir.NewSelectorExpr(pos, ir.ODOTPTR, ptr, field.Sym) sel.Selection = field sel.SetType(field.Type) sel.SetTypecheck(1) sel.SetBounded(true) // guaranteed not to fault return sel } func runtimeField(name string, offset int64, typ *types.Type) *types.Field { f := types.NewField(src.NoXPos, ir.Pkgs.Runtime.Lookup(name), typ) f.Offset = offset
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Feb 27 20:56:00 UTC 2024 - 10.4K bytes - Viewed (0) -
src/cmd/compile/internal/walk/expr.go
} t := n.X.Type() if t != nil && t.IsPtr() { t = t.Elem() } if t.IsArray() { n.SetBounded(bounded(r, t.NumElem())) if base.Flag.LowerM != 0 && n.Bounded() && !ir.IsConst(n.Index, constant.Int) { base.Warn("index bounds check elided") } } else if ir.IsConst(n.X, constant.String) { n.SetBounded(bounded(r, int64(len(ir.StringVal(n.X)))))
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 04 17:34:01 UTC 2024 - 27.6K bytes - Viewed (0) -
src/cmd/compile/internal/walk/builtin.go
nif.Likely = true // then { s = s[:n] } slice := ir.NewSliceExpr(base.Pos, ir.OSLICE, s, nil, newLen, nil) slice.SetBounded(true) nif.Body = []ir.Node{ ir.NewAssignStmt(base.Pos, s, slice), } // else { s = growslice(s.ptr, n, s.cap, a, T) } nif.Else = []ir.Node{
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Mar 08 22:35:22 UTC 2024 - 31.2K bytes - Viewed (0) -
src/cmd/compile/internal/walk/order.go
if mk.Esc() == ir.EscNone || mk.Len == nil || mk.Cap != nil { return } mk.SetOp(ir.OMAKESLICECOPY) mk.Cap = cp.Y // Set bounded when m = OMAKESLICE([]T, len(s)); OCOPY(m, s) mk.SetBounded(mk.Len.Op() == ir.OLEN && ir.SameSafeExpr(mk.Len.(*ir.UnaryExpr).X, cp.Y)) as.Y = typecheck.Expr(mk) s[1] = nil // remove separate copy call } // edge inserts coverage instrumentation for libfuzzer.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Mar 08 02:00:33 UTC 2024 - 42.7K bytes - Viewed (0)