Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 16 of 16 for BlockStmt (0.45 sec)

  1. src/go/ast/example_test.go

    	//     19  .  .  .  .  Params: *ast.FieldList {
    	//     20  .  .  .  .  .  Opening: 3:10
    	//     21  .  .  .  .  .  Closing: 3:11
    	//     22  .  .  .  .  }
    	//     23  .  .  .  }
    	//     24  .  .  .  Body: *ast.BlockStmt {
    	//     25  .  .  .  .  Lbrace: 3:13
    	//     26  .  .  .  .  List: []ast.Stmt (len = 1) {
    	//     27  .  .  .  .  .  0: *ast.ExprStmt {
    	//     28  .  .  .  .  .  .  X: *ast.CallExpr {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 21:44:50 UTC 2024
    - 6.1K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/walk/stmt.go

    	case ir.OBREAK,
    		ir.OCONTINUE,
    		ir.OFALL,
    		ir.OGOTO,
    		ir.OLABEL,
    		ir.OJUMPTABLE,
    		ir.OINTERFACESWITCH,
    		ir.ODCL,
    		ir.OCHECKNIL:
    		return n
    
    	case ir.OBLOCK:
    		n := n.(*ir.BlockStmt)
    		walkStmtList(n.List)
    		return n
    
    	case ir.OCASE:
    		base.Errorf("case statement out of place")
    		panic("unreachable")
    
    	case ir.ODEFER:
    		n := n.(*ir.GoDeferStmt)
    		ir.CurFunc.SetHasDefer(true)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Oct 06 15:42:30 UTC 2023
    - 4.7K bytes
    - Viewed (0)
  3. src/cmd/vendor/golang.org/x/tools/go/analysis/passes/httpresponse/httpresponse.go

    // node, along with the number of call expressions encountered.
    func restOfBlock(stack []ast.Node) ([]ast.Stmt, int) {
    	var ncalls int
    	for i := len(stack) - 1; i >= 0; i-- {
    		if b, ok := stack[i].(*ast.BlockStmt); ok {
    			for j, v := range b.List {
    				if v == stack[i+1] {
    					return b.List[j:], ncalls
    				}
    			}
    			break
    		}
    
    		if _, ok := stack[i].(*ast.CallExpr); ok {
    			ncalls++
    		}
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 02:20:05 UTC 2024
    - 5K bytes
    - Viewed (0)
  4. src/go/ast/walk.go

    		Walk(v, n.Call)
    
    	case *DeferStmt:
    		Walk(v, n.Call)
    
    	case *ReturnStmt:
    		walkList(v, n.Results)
    
    	case *BranchStmt:
    		if n.Label != nil {
    			Walk(v, n.Label)
    		}
    
    	case *BlockStmt:
    		walkList(v, n.List)
    
    	case *IfStmt:
    		if n.Init != nil {
    			Walk(v, n.Init)
    		}
    		Walk(v, n.Cond)
    		Walk(v, n.Body)
    		if n.Else != nil {
    			Walk(v, n.Else)
    		}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 16 16:34:10 UTC 2024
    - 6.4K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/syntax/walk.go

    		w.node(n.Value)
    
    	case *ChanType:
    		w.node(n.Elem)
    
    	// statements
    	case *EmptyStmt: // nothing to do
    
    	case *LabeledStmt:
    		w.node(n.Label)
    		w.node(n.Stmt)
    
    	case *BlockStmt:
    		w.stmtList(n.List)
    
    	case *ExprStmt:
    		w.node(n.X)
    
    	case *SendStmt:
    		w.node(n.Chan)
    		w.node(n.Value)
    
    	case *DeclStmt:
    		w.declList(n.DeclList)
    
    	case *AssignStmt:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jan 17 19:55:04 UTC 2023
    - 5.7K bytes
    - Viewed (0)
  6. src/cmd/compile/internal/syntax/nodes_test.go

    	{"Field", `@x, y, z T`},
    	{"Field", `@x, y, z (*T)`},
    }
    
    var stmts = []test{
    	{"EmptyStmt", `@`},
    
    	{"LabeledStmt", `L@:`},
    	{"LabeledStmt", `L@: ;`},
    	{"LabeledStmt", `L@: f()`},
    
    	{"BlockStmt", `@{}`},
    
    	// The position of an ExprStmt is the position of the expression.
    	{"ExprStmt", `@<-ch`},
    	{"ExprStmt", `f@()`},
    	{"ExprStmt", `append@(s, 1, 2, 3)`},
    
    	{"SendStmt", `ch @<- x`},
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 02 18:45:06 UTC 2023
    - 8.7K bytes
    - Viewed (0)
Back to top