Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for rand_fn (0.18 sec)

  1. cmd/test-utils_test.go

    }
    
    // nextSuffix - provides a new unique suffix every time the function is called.
    func nextSuffix() string {
    	randmu.Lock()
    	r := randN
    	// Initial seed required, generate one.
    	if r == 0 {
    		r = reseed()
    	}
    	// constants from Numerical Recipes
    	r = r*1664525 + 1013904223
    	randN = r
    	randmu.Unlock()
    	return strconv.Itoa(int(1e9 + r%1e9))[1:]
    }
    
    // isSameType - compares two object types via reflect.TypeOf
    Go
    - Registered: Sun Apr 14 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:06:57 GMT 2024
    - 75.7K bytes
    - Viewed (0)
Back to top