Search Options

Results per page
Sort
Preferred Languages
Advance

Results 91 - 100 of 106 for callExpr (0.13 sec)

  1. src/go/types/check.go

    	inTParamList  bool                   // set if inside a type parameter list
    	sig           *Signature             // function signature if inside a function; nil otherwise
    	isPanic       map[*ast.CallExpr]bool // set of panic call expressions (used for termination check)
    	hasLabel      bool                   // set if a function makes use of labels (only ~1% of functions); unused outside functions
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 23.1K bytes
    - Viewed (0)
  2. src/go/types/api_test.go

    	}
    	conf.Check("p", fset, []*ast.File{f}, info) // ignore result
    	for e, tv := range info.Types {
    		if _, ok := e.(*ast.CallExpr); ok {
    			if tv.Type != Typ[Int16] {
    				t.Errorf("CallExpr has type %v, want int16", tv.Type)
    			}
    			return
    		}
    	}
    	t.Errorf("CallExpr has no type")
    }
    
    // TestCompositeLitTypes verifies that Info.Types registers the correct
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 94.2K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/syntax/printer.go

    		p.print(n.X, _Dot, _Lparen, n.Type, _Rparen)
    
    	case *TypeSwitchGuard:
    		if n.Lhs != nil {
    			p.print(n.Lhs, blank, _Define, blank)
    		}
    		p.print(n.X, _Dot, _Lparen, _Type, _Rparen)
    
    	case *CallExpr:
    		p.print(n.Fun, _Lparen)
    		p.printExprList(n.ArgList)
    		if n.HasDots {
    			p.print(_DotDotDot)
    		}
    		p.print(_Rparen)
    
    	case *Operation:
    		if n.Y == nil {
    			// unary expr
    			p.print(n.Op)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Aug 24 07:17:27 UTC 2023
    - 21.5K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/types2/check.go

    	inTParamList  bool                      // set if inside a type parameter list
    	sig           *Signature                // function signature if inside a function; nil otherwise
    	isPanic       map[*syntax.CallExpr]bool // set of panic call expressions (used for termination check)
    	hasLabel      bool                      // set if a function makes use of labels (only ~1% of functions); unused outside functions
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 23.3K bytes
    - Viewed (0)
  5. staging/src/k8s.io/apiserver/pkg/apis/apiserver/validation/validation.go

    		if s == nil {
    			return false
    		}
    		if isIdentOperand(s.Operand, operand) && s.Field == field {
    			return true
    		}
    		return hasSelectExp(s.Operand, operand, field)
    	case *exprpb.Expr_CallExpr:
    		c := e.CallExpr
    		if c == nil {
    			return false
    		}
    		if c.Target == nil && c.Function == operators.OptSelect && len(c.Args) == 2 &&
    			isIdentOperand(c.Args[0], operand) && isConstField(c.Args[1], field) {
    			return true
    		}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 10 22:07:40 UTC 2024
    - 31.3K bytes
    - Viewed (0)
  6. src/cmd/compile/internal/types2/infer.go

    	case *Tuple:
    		// This case does not occur from within isParameterized
    		// because tuples only appear in signatures where they
    		// are handled explicitly. But isParameterized is also
    		// called by Checker.callExpr with a function result tuple
    		// if instantiation failed (go.dev/issue/59890).
    		return t != nil && w.varList(t.vars)
    
    	case *Signature:
    		// t.tparams may not be nil if we are looking at a signature
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 24 13:54:20 UTC 2024
    - 26.4K bytes
    - Viewed (0)
  7. src/go/types/infer.go

    	case *Tuple:
    		// This case does not occur from within isParameterized
    		// because tuples only appear in signatures where they
    		// are handled explicitly. But isParameterized is also
    		// called by Checker.callExpr with a function result tuple
    		// if instantiation failed (go.dev/issue/59890).
    		return t != nil && w.varList(t.vars)
    
    	case *Signature:
    		// t.tparams may not be nil if we are looking at a signature
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 24 13:54:20 UTC 2024
    - 26.5K bytes
    - Viewed (0)
  8. src/cmd/doc/pkg.go

    	case *ast.MapType:
    		key := pkg.oneLineNodeDepth(n.Key, depth)
    		value := pkg.oneLineNodeDepth(n.Value, depth)
    		return fmt.Sprintf("map[%s]%s", key, value)
    
    	case *ast.CallExpr:
    		fnc := pkg.oneLineNodeDepth(n.Fun, depth)
    		var args []string
    		for _, arg := range n.Args {
    			args = append(args, pkg.oneLineNodeDepth(arg, depth))
    		}
    		return fmt.Sprintf("%s(%s)", fnc, joinStrings(args))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jan 08 20:15:52 UTC 2024
    - 32K bytes
    - Viewed (0)
  9. src/go/types/stmt.go

    	if token.ADD_ASSIGN <= op && op <= token.AND_NOT_ASSIGN {
    		return op + (token.ADD - token.ADD_ASSIGN)
    	}
    	return token.ILLEGAL
    }
    
    func (check *Checker) suspendedCall(keyword string, call *ast.CallExpr) {
    	var x operand
    	var msg string
    	var code Code
    	switch check.rawExpr(nil, &x, call, nil, false) {
    	case conversion:
    		msg = "requires function call, not conversion"
    		code = InvalidDefer
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 30.6K bytes
    - Viewed (0)
  10. src/cmd/compile/internal/types2/stmt.go

    }
    
    func (check *Checker) suspendedCall(keyword string, call syntax.Expr) {
    	code := InvalidDefer
    	if keyword == "go" {
    		code = InvalidGo
    	}
    
    	if _, ok := call.(*syntax.CallExpr); !ok {
    		check.errorf(call, code, "expression in %s must be function call", keyword)
    		check.use(call)
    		return
    	}
    
    	var x operand
    	var msg string
    	switch check.rawExpr(nil, &x, call, nil, false) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 30.7K bytes
    - Viewed (0)
Back to top