Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for Byval (0.05 sec)

  1. src/go/types/expr.go

    	// Check that constants are representable by uint, but do not convert them
    	// (see also go.dev/issue/47243).
    	var yval constant.Value
    	if y.mode == constant_ {
    		// Provide a good error message for negative shift counts.
    		yval = constant.ToInt(y.val) // consider -1, 1.0, but not -1.1
    		if yval.Kind() == constant.Int && constant.Sign(yval) < 0 {
    			check.errorf(y, InvalidShiftCount, invalidOp+"negative shift count %s", y)
    			x.mode = invalid
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 02:09:54 UTC 2024
    - 49.7K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/types2/expr.go

    	// Check that constants are representable by uint, but do not convert them
    	// (see also go.dev/issue/47243).
    	var yval constant.Value
    	if y.mode == constant_ {
    		// Provide a good error message for negative shift counts.
    		yval = constant.ToInt(y.val) // consider -1, 1.0, but not -1.1
    		if yval.Kind() == constant.Int && constant.Sign(yval) < 0 {
    			check.errorf(y, InvalidShiftCount, invalidOp+"negative shift count %s", y)
    			x.mode = invalid
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 02:09:54 UTC 2024
    - 51.7K bytes
    - Viewed (0)
Back to top