Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for AssertExpr (0.14 sec)

  1. src/cmd/compile/internal/syntax/positions.go

    			}
    			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 {
    				m = n.X
    				continue
    			}
    			return n.Pos()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 10 17:49:19 UTC 2024
    - 6.5K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/syntax/walk.go

    	case *IndexExpr:
    		w.node(n.X)
    		w.node(n.Index)
    
    	case *SliceExpr:
    		w.node(n.X)
    		for _, x := range n.Index {
    			if x != nil {
    				w.node(x)
    			}
    		}
    
    	case *AssertExpr:
    		w.node(n.X)
    		w.node(n.Type)
    
    	case *TypeSwitchGuard:
    		if n.Lhs != nil {
    			w.node(n.Lhs)
    		}
    		w.node(n.X)
    
    	case *Operation:
    		w.node(n.X)
    		if n.Y != nil {
    			w.node(n.Y)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jan 17 19:55:04 UTC 2023
    - 5.7K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/syntax/nodes_test.go

    	{"SelectorExpr", `a@.b`},
    	{"IndexExpr", `a@[i]`},
    
    	{"SliceExpr", `a@[:]`},
    	{"SliceExpr", `a@[i:]`},
    	{"SliceExpr", `a@[:j]`},
    	{"SliceExpr", `a@[i:j]`},
    	{"SliceExpr", `a@[i:j:k]`},
    
    	{"AssertExpr", `x@.(T)`},
    
    	{"Operation", `@*b`},
    	{"Operation", `@+b`},
    	{"Operation", `@-b`},
    	{"Operation", `@!b`},
    	{"Operation", `@^b`},
    	{"Operation", `@&b`},
    	{"Operation", `@<-b`},
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 02 18:45:06 UTC 2023
    - 8.7K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/syntax/nodes.go

    		// TODO(mdempsky): This is only needed to report the "3-index
    		// slice of string" error when Index[2] is missing.
    		Full bool
    		expr
    	}
    
    	// X.(Type)
    	AssertExpr struct {
    		X    Expr
    		Type Expr
    		expr
    	}
    
    	// X.(type)
    	// Lhs := X.(type)
    	TypeSwitchGuard struct {
    		Lhs *Name // nil means no Lhs :=
    		X   Expr  // X.(type)
    		expr
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Sep 20 14:52:38 UTC 2023
    - 9K bytes
    - Viewed (0)
Back to top