Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for mod_sqrt (0.63 sec)

  1. src/cmd/go/internal/gover/mod_test.go

    	{"toolchain", "v1.2", false},
    	{"rsc.io/quote", "v1.2", true},
    	{"rsc.io/quote", "1.2", false},
    }
    
    func TestModSort(t *testing.T) {
    	test1(t, modSortTests, "ModSort", func(list []module.Version) []module.Version {
    		out := slices.Clone(list)
    		ModSort(out)
    		return out
    	})
    }
    
    var modSortTests = []testCase1[[]module.Version, []module.Version]{
    	{
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 25 17:51:28 UTC 2023
    - 2K bytes
    - Viewed (0)
  2. src/math/big/alias_test.go

    		},
    		"ModInverse": func(v, x bigInt, y notZeroInt) bool {
    			return checkAliasingTwoArgs(t, (*big.Int).ModInverse, v.Int, x.Int, y.Int)
    		},
    		"ModSqrt": func(v, x bigInt, p prime) bool {
    			return checkAliasingTwoArgs(t, (*big.Int).ModSqrt, v.Int, x.Int, p.Int)
    		},
    		"Mul": func(v, x, y bigInt) bool {
    			return checkAliasingTwoArgs(t, (*big.Int).Mul, v.Int, x.Int, y.Int)
    		},
    		"Neg": func(v, x bigInt) bool {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 19 15:49:05 UTC 2022
    - 8.8K bytes
    - Viewed (0)
  3. src/cmd/go/internal/gover/mod.go

    	}
    	if path == "toolchain" {
    		return Compare(maybeToolchainVersion(x), maybeToolchainVersion(y))
    	}
    	return semver.Compare(x, y)
    }
    
    // ModSort is like module.Sort but understands the "go" and "toolchain"
    // modules and their version ordering.
    func ModSort(list []module.Version) {
    	sort.Slice(list, func(i, j int) bool {
    		mi := list[i]
    		mj := list[j]
    		if mi.Path != mj.Path {
    			return mi.Path < mj.Path
    		}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 06 19:18:46 UTC 2023
    - 3.4K bytes
    - Viewed (0)
  4. src/cmd/go/internal/workcmd/sync.go

    			if r := modload.PackageModule(pkg); r.Version != "" && !inMustSelect[r] {
    				// r has a known version, so force that version.
    				mustSelect = append(mustSelect, r)
    				inMustSelect[r] = true
    			}
    		}
    		gover.ModSort(mustSelect) // ensure determinism
    		mustSelectFor[m] = mustSelect
    	}
    
    	workFilePath := modload.WorkFilePath() // save go.work path because EnterModule clobbers it.
    
    	var goV string
    	for _, m := range mms.Versions() {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat Jun 03 21:13:11 UTC 2023
    - 4.6K bytes
    - Viewed (0)
  5. src/cmd/go/internal/mvs/graph.go

    		seenRoot[r.Path] = true
    	}
    	uniqueRoots := list
    
    	for path, version := range g.selected {
    		if !seenRoot[path] {
    			list = append(list, module.Version{Path: path, Version: version})
    		}
    	}
    	gover.ModSort(list[len(uniqueRoots):])
    
    	return list
    }
    
    // WalkBreadthFirst invokes f once, in breadth-first order, for each module
    // version other than "none" that appears in the graph, regardless of whether
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Jun 01 02:52:19 UTC 2023
    - 6.3K bytes
    - Viewed (0)
  6. src/crypto/elliptic/elliptic.go

    		return nil, nil
    	}
    	p := curve.Params().P
    	x = new(big.Int).SetBytes(data[1:])
    	if x.Cmp(p) >= 0 {
    		return nil, nil
    	}
    	// y² = x³ - 3x + b
    	y = curve.Params().polynomial(x)
    	y = y.ModSqrt(y, p)
    	if y == nil {
    		return nil, nil
    	}
    	if byte(y.Bit(0)) != data[0]&1 {
    		y.Neg(y).Mod(y, p)
    	}
    	if !curve.IsOnCurve(x, y) {
    		return nil, nil
    	}
    	return
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Oct 13 17:09:47 UTC 2023
    - 9K bytes
    - Viewed (0)
Back to top