1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78
|
// Code generated by 'yaegi extract math/rand'. DO NOT EDIT.
//go:build go1.22
// +build go1.22
package stdlib
import (
"math/rand"
"reflect"
)
func init() {
Symbols["math/rand/rand"] = map[string]reflect.Value{
// function, constant and variable definitions
"ExpFloat64": reflect.ValueOf(rand.ExpFloat64),
"Float32": reflect.ValueOf(rand.Float32),
"Float64": reflect.ValueOf(rand.Float64),
"Int": reflect.ValueOf(rand.Int),
"Int31": reflect.ValueOf(rand.Int31),
"Int31n": reflect.ValueOf(rand.Int31n),
"Int63": reflect.ValueOf(rand.Int63),
"Int63n": reflect.ValueOf(rand.Int63n),
"Intn": reflect.ValueOf(rand.Intn),
"New": reflect.ValueOf(rand.New),
"NewSource": reflect.ValueOf(rand.NewSource),
"NewZipf": reflect.ValueOf(rand.NewZipf),
"NormFloat64": reflect.ValueOf(rand.NormFloat64),
"Perm": reflect.ValueOf(rand.Perm),
"Read": reflect.ValueOf(rand.Read),
"Seed": reflect.ValueOf(rand.Seed),
"Shuffle": reflect.ValueOf(rand.Shuffle),
"Uint32": reflect.ValueOf(rand.Uint32),
"Uint64": reflect.ValueOf(rand.Uint64),
// type definitions
"Rand": reflect.ValueOf((*rand.Rand)(nil)),
"Source": reflect.ValueOf((*rand.Source)(nil)),
"Source64": reflect.ValueOf((*rand.Source64)(nil)),
"Zipf": reflect.ValueOf((*rand.Zipf)(nil)),
// interface wrapper definitions
"_Source": reflect.ValueOf((*_math_rand_Source)(nil)),
"_Source64": reflect.ValueOf((*_math_rand_Source64)(nil)),
}
}
// _math_rand_Source is an interface wrapper for Source type
type _math_rand_Source struct {
IValue interface{}
WInt63 func() int64
WSeed func(seed int64)
}
func (W _math_rand_Source) Int63() int64 {
return W.WInt63()
}
func (W _math_rand_Source) Seed(seed int64) {
W.WSeed(seed)
}
// _math_rand_Source64 is an interface wrapper for Source64 type
type _math_rand_Source64 struct {
IValue interface{}
WInt63 func() int64
WSeed func(seed int64)
WUint64 func() uint64
}
func (W _math_rand_Source64) Int63() int64 {
return W.WInt63()
}
func (W _math_rand_Source64) Seed(seed int64) {
W.WSeed(seed)
}
func (W _math_rand_Source64) Uint64() uint64 {
return W.WUint64()
}
|