Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 19 of 19 for FuncLit (0.11 sec)

  1. src/go/parser/parser_test.go

    	{name: "go", format: "package main; func main() { «go func() { «» }()» }", parseMultiplier: 2, scope: true},                      // Parser nodes: GoStmt, FuncLit
    	{name: "defer", format: "package main; func main() { «defer func() { «» }()» }", parseMultiplier: 2, scope: true},                // Parser nodes: DeferStmt, FuncLit
    	{name: "select", format: "package main; func main() { «select { default: «» }» }", scope: true},
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 31 20:26:14 UTC 2024
    - 24.6K bytes
    - Viewed (0)
  2. src/cmd/vendor/golang.org/x/tools/go/analysis/passes/tests/tests.go

    			return true
    		}
    	}
    	return false
    }
    
    // Validate the arguments of fuzz target.
    func validateFuzzArgs(pass *analysis.Pass, params *types.Tuple, expr ast.Expr) bool {
    	fLit, isFuncLit := expr.(*ast.FuncLit)
    	exprRange := expr
    	ok := true
    	if !isTestingType(params.At(0).Type(), "T") {
    		if isFuncLit {
    			exprRange = fLit.Type.Params.List[0].Type
    		}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 03 02:38:00 UTC 2024
    - 14.4K bytes
    - Viewed (0)
  3. src/cmd/cover/cover.go

    				walkBody = false
    			}
    		}
    		if walkBody {
    			ast.Walk(f, n.Body)
    		}
    		if *pkgcfg != "" {
    			flit := false
    			f.postFunc(n, fname, flit, n.Body)
    		}
    		return nil
    	case *ast.FuncLit:
    		// For function literals enclosed in functions, just glom the
    		// code for the literal in with the enclosing function (for now).
    		if f.fn.counterVar != "" {
    			return f
    		}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 14 19:41:17 UTC 2024
    - 34.5K bytes
    - Viewed (0)
  4. src/go/types/api.go

    	// type parameters, parameters, and named results, plus any
    	// local declarations in the body block.
    	// It is coextensive with the complete extent of the
    	// function's syntax ([*ast.FuncDecl] or [*ast.FuncLit]).
    	// The Scopes mapping does not contain an entry for the
    	// function body ([*ast.BlockStmt]); the function's scope is
    	// associated with the [*ast.FuncType].
    	//
    	// The following node types may appear in Scopes:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 19:57:43 UTC 2024
    - 17.2K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/types2/api.go

    	// type parameters, parameters, and named results, plus any
    	// local declarations in the body block.
    	// It is coextensive with the complete extent of the
    	// function's syntax ([*ast.FuncDecl] or [*ast.FuncLit]).
    	// The Scopes mapping does not contain an entry for the
    	// function body ([*ast.BlockStmt]); the function's scope is
    	// associated with the [*ast.FuncType].
    	//
    	// The following node types may appear in Scopes:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 10 13:48:53 UTC 2024
    - 17.4K bytes
    - Viewed (0)
  6. src/go/types/expr.go

    	old, found := check.untyped[x]
    	if !found {
    		return // nothing to do
    	}
    
    	// update operands of x if necessary
    	switch x := x.(type) {
    	case *ast.BadExpr,
    		*ast.FuncLit,
    		*ast.CompositeLit,
    		*ast.IndexExpr,
    		*ast.SliceExpr,
    		*ast.TypeAssertExpr,
    		*ast.StarExpr,
    		*ast.KeyValueExpr,
    		*ast.ArrayType,
    		*ast.StructType,
    		*ast.FuncType,
    		*ast.InterfaceType,
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 02:09:54 UTC 2024
    - 49.7K bytes
    - Viewed (0)
  7. src/cmd/compile/internal/types2/expr.go

    	old, found := check.untyped[x]
    	if !found {
    		return // nothing to do
    	}
    
    	// update operands of x if necessary
    	switch x := x.(type) {
    	case *syntax.BadExpr,
    		*syntax.FuncLit,
    		*syntax.CompositeLit,
    		*syntax.IndexExpr,
    		*syntax.SliceExpr,
    		*syntax.AssertExpr,
    		*syntax.ListExpr,
    		//*syntax.StarExpr,
    		*syntax.KeyValueExpr,
    		*syntax.ArrayType,
    		*syntax.StructType,
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 02:09:54 UTC 2024
    - 51.7K bytes
    - Viewed (0)
  8. src/cmd/compile/internal/syntax/parser.go

    			px.X = x
    			x = px
    		}
    		return x
    
    	case _Func:
    		pos := p.pos()
    		p.next()
    		_, ftyp := p.funcType("function type")
    		if p.tok == _Lbrace {
    			p.xnest++
    
    			f := new(FuncLit)
    			f.pos = pos
    			f.Type = ftyp
    			f.Body = p.funcBody()
    
    			p.xnest--
    			return f
    		}
    		return ftyp
    
    	case _Lbrack, _Chan, _Map, _Struct, _Interface:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 62.9K bytes
    - Viewed (0)
  9. src/cmd/vendor/golang.org/x/tools/internal/stdlib/manifest.go

    		{"FuncDecl.Body", Field, 0},
    		{"FuncDecl.Doc", Field, 0},
    		{"FuncDecl.Name", Field, 0},
    		{"FuncDecl.Recv", Field, 0},
    		{"FuncDecl.Type", Field, 0},
    		{"FuncLit", Type, 0},
    		{"FuncLit.Body", Field, 0},
    		{"FuncLit.Type", Field, 0},
    		{"FuncType", Type, 0},
    		{"FuncType.Func", Field, 0},
    		{"FuncType.Params", Field, 0},
    		{"FuncType.Results", Field, 0},
    		{"FuncType.TypeParams", Field, 18},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 02:20:05 UTC 2024
    - 534.2K bytes
    - Viewed (0)
Back to top