- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 19 for IndexExpr (0.31 sec)
-
src/cmd/vendor/golang.org/x/tools/internal/typeparams/common.go
switch e := n.(type) { case *ast.IndexExpr: return e.X, e.Lbrack, []ast.Expr{e.Index}, e.Rbrack case *ast.IndexListExpr: return e.X, e.Lbrack, e.Indices, e.Rbrack } return nil, token.NoPos, nil, token.NoPos } // PackIndexExpr returns an *ast.IndexExpr or *ast.IndexListExpr, depending on // the cardinality of indices. Calling PackIndexExpr with len(indices) == 0
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 03 02:38:00 UTC 2024 - 4.3K bytes - Viewed (0) -
src/cmd/compile/internal/types2/call.go
return inst } func (check *Checker) callExpr(x *operand, call *syntax.CallExpr) exprKind { var inst *syntax.IndexExpr // function instantiation, if any if iexpr, _ := call.Fun.(*syntax.IndexExpr); iexpr != nil { if check.indexExpr(x, iexpr) { // Delay function instantiation to argument checking, // where we combine type and value arguments for type // inference.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 31.5K bytes - Viewed (0) -
src/cmd/compile/internal/syntax/positions.go
if n.Type != nil { m = n.Type continue } return n.Pos() case *KeyValueExpr: m = n.Key // case *FuncLit: // case *ParenExpr: case *SelectorExpr: m = n.X case *IndexExpr: m = n.X // case *SliceExpr: case *AssertExpr: m = n.X case *TypeSwitchGuard: if n.Lhs != nil { m = n.Lhs continue } m = n.X case *Operation: if n.Y != nil {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Jun 10 17:49:19 UTC 2024 - 6.5K bytes - Viewed (0) -
src/cmd/compile/internal/walk/assign.go
left, right = n.X, n.Y } // Recognize m[k] = append(m[k], ...) so we can reuse // the mapassign call. var mapAppend *ir.CallExpr if left.Op() == ir.OINDEXMAP && right.Op() == ir.OAPPEND { left := left.(*ir.IndexExpr) mapAppend = right.(*ir.CallExpr) if !ir.SameSafeExpr(left, mapAppend.Args[0]) { base.Fatalf("not same expressions: %v != %v", left, mapAppend.Args[0]) } } left = walkExpr(left, init)
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/go/types/call.go
// unchanged. // // If an error (other than a version error) occurs in any case, it is reported // and x.mode is set to invalid. func (check *Checker) funcInst(T *target, pos token.Pos, x *operand, ix *typeparams.IndexExpr, infer bool) ([]Type, []ast.Expr) { assert(T != nil || ix != nil) var instErrPos positioner if ix != nil { instErrPos = inNode(ix.Orig, ix.Lbrack)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 33.5K bytes - Viewed (0) -
src/cmd/compile/internal/syntax/parser.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 62.9K bytes - Viewed (0) -
src/go/ast/walk.go
case *CompositeLit: if n.Type != nil { Walk(v, n.Type) } walkList(v, n.Elts) case *ParenExpr: Walk(v, n.X) case *SelectorExpr: Walk(v, n.X) Walk(v, n.Sel) case *IndexExpr: Walk(v, n.X) Walk(v, n.Index) case *IndexListExpr: Walk(v, n.X) walkList(v, n.Indices) case *SliceExpr: Walk(v, n.X) if n.Low != nil { Walk(v, n.Low) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 16 16:34:10 UTC 2024 - 6.4K bytes - Viewed (0) -
src/go/types/typexpr.go
case invalid: // ignore - error reported before case novalue: check.errorf(&x, NotAType, "%s used as type", &x) default: check.errorf(&x, NotAType, "%s is not a type", &x) } case *ast.IndexExpr, *ast.IndexListExpr: ix := typeparams.UnpackIndexExpr(e) check.verifyVersionf(inNode(e, ix.Lbrack), go1_18, "type instantiation") return check.instantiatedType(ix, def) case *ast.ParenExpr:
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 16.3K bytes - Viewed (0) -
src/go/doc/reader.go
func recvString(recv ast.Expr) string { switch t := recv.(type) { case *ast.Ident: return t.Name case *ast.StarExpr: return "*" + recvString(t.X) case *ast.IndexExpr: // Generic type with one parameter. return fmt.Sprintf("%s[%s]", recvString(t.X), recvParam(t.Index)) case *ast.IndexListExpr: // Generic type with multiple parameters. if len(t.Indices) > 0 {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 27.5K bytes - Viewed (0) -
src/go/types/expr.go
kind := check.rawExpr(nil, x, e.X, nil, false) x.expr = e return kind case *ast.SelectorExpr: check.selector(x, e, nil, false) case *ast.IndexExpr, *ast.IndexListExpr: ix := typeparams.UnpackIndexExpr(e) if check.indexExpr(x, ix) { if !enableReverseTypeInference { T = nil } check.funcInst(T, e.Pos(), x, ix, true) } if x.mode == invalid { goto Error
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 29 02:09:54 UTC 2024 - 49.7K bytes - Viewed (0)