Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for versionErrorf (0.18 sec)

  1. src/cmd/compile/internal/types2/version.go

    // which are used to report a version error if allowVersion returns false.
    func (check *Checker) verifyVersionf(at poser, v goVersion, format string, args ...interface{}) bool {
    	if !check.allowVersion(at, v) {
    		check.versionErrorf(at, v, format, args...)
    		return false
    	}
    	return true
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 20 20:44:57 UTC 2024
    - 2.4K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/types2/call.go

    		var reverse bool
    		if T != nil && sig.tparams != nil {
    			if !versionErr && !check.allowVersion(instErrPos, go1_21) {
    				if inst != nil {
    					check.versionErrorf(instErrPos, go1_21, "partially instantiated function in assignment")
    				} else {
    					check.versionErrorf(instErrPos, go1_21, "implicitly instantiated function in assignment")
    				}
    			}
    			gsig := NewSignatureType(nil, nil, nil, sig.params, sig.results, sig.variadic)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 31.5K bytes
    - Viewed (0)
  3. src/go/types/call.go

    		var reverse bool
    		if T != nil && sig.tparams != nil {
    			if !versionErr && !check.allowVersion(instErrPos, go1_21) {
    				if ix != nil {
    					check.versionErrorf(instErrPos, go1_21, "partially instantiated function in assignment")
    				} else {
    					check.versionErrorf(instErrPos, go1_21, "implicitly instantiated function in assignment")
    				}
    			}
    			gsig := NewSignatureType(nil, nil, nil, sig.params, sig.results, sig.variadic)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 33.5K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/types2/conversions.go

    			if Identical(s.Elem(), a.Elem()) {
    				if check == nil || check.allowVersion(x, go1_20) {
    					return true
    				}
    				// check != nil
    				if cause != nil {
    					// TODO(gri) consider restructuring versionErrorf so we can use it here and below
    					*cause = "conversion of slice to array requires go1.20 or later"
    				}
    				return false
    			}
    		case *Pointer:
    			if a, _ := under(a.Elem()).(*Array); a != nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 18:51:00 UTC 2024
    - 9K bytes
    - Viewed (0)
  5. src/go/types/conversions.go

    			if Identical(s.Elem(), a.Elem()) {
    				if check == nil || check.allowVersion(x, go1_20) {
    					return true
    				}
    				// check != nil
    				if cause != nil {
    					// TODO(gri) consider restructuring versionErrorf so we can use it here and below
    					*cause = "conversion of slice to array requires go1.20 or later"
    				}
    				return false
    			}
    		case *Pointer:
    			if a, _ := under(a.Elem()).(*Array); a != nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 18:51:00 UTC 2024
    - 9.1K bytes
    - Viewed (0)
  6. src/go/types/expr.go

    	}
    	// len(s) > 2
    	if strings.Contains(s, "_") {
    		check.versionErrorf(lit, go1_13, "underscore in numeric literal")
    		return
    	}
    	if s[0] != '0' {
    		return
    	}
    	radix := s[1]
    	if radix == 'b' || radix == 'B' {
    		check.versionErrorf(lit, go1_13, "binary literal")
    		return
    	}
    	if radix == 'o' || radix == 'O' {
    		check.versionErrorf(lit, go1_13, "0o/0O-style octal literal")
    		return
    	}
    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

    	}
    	// len(s) > 2
    	if strings.Contains(s, "_") {
    		check.versionErrorf(lit, go1_13, "underscore in numeric literal")
    		return
    	}
    	if s[0] != '0' {
    		return
    	}
    	radix := s[1]
    	if radix == 'b' || radix == 'B' {
    		check.versionErrorf(lit, go1_13, "binary literal")
    		return
    	}
    	if radix == 'o' || radix == 'O' {
    		check.versionErrorf(lit, go1_13, "0o/0O-style octal literal")
    		return
    	}
    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/go/internal/modfetch/fetch.go

    		if err != nil {
    			base.Fatalf("verifying %v", module.VersionError(mod, err))
    		}
    		err = hashZip(mod, zip, ziphash)
    		if err != nil {
    			base.Fatalf("verifying %v", module.VersionError(mod, err))
    		}
    		return
    	}
    	h := string(data)
    	if !strings.HasPrefix(h, "h1:") {
    		base.Fatalf("verifying %v", module.VersionError(mod, fmt.Errorf("unexpected ziphash: %q", h)))
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 14:56:56 UTC 2024
    - 30.3K bytes
    - Viewed (0)
  9. src/cmd/vendor/golang.org/x/mod/module/module.go

    // A ModuleError indicates an error specific to a module.
    type ModuleError struct {
    	Path    string
    	Version string
    	Err     error
    }
    
    // VersionError returns a [ModuleError] derived from a [Version] and error,
    // or err itself if it is already such an error.
    func VersionError(v Version, err error) error {
    	var mErr *ModuleError
    	if errors.As(err, &mErr) && mErr.Path == v.Path && mErr.Version == v.Version {
    		return err
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 09 20:17:07 UTC 2024
    - 26.9K bytes
    - Viewed (0)
  10. src/cmd/go/internal/modload/import.go

    				} else {
    					err = fmt.Errorf("replacement directory %s: %w", r.Path, err)
    				}
    				return dir, true, module.VersionError(mod, err)
    			}
    			return dir, true, nil
    		}
    		mod = r
    	}
    
    	if mustHaveSums() && !modfetch.HaveSum(mod) {
    		return "", false, module.VersionError(mod, &sumMissingError{})
    	}
    
    	dir, err = modfetch.Download(ctx, mod)
    	return dir, false, err
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 15:21:14 UTC 2024
    - 27.7K bytes
    - Viewed (0)
Back to top