예제 #1
0
파일: random.go 프로젝트: haskelladdict/gsl
// Memcpy copies the random number generator src into the pre-existing
// generator dest, making dest into an exact copy of src. The two generators
// must be of the same type.
// NOTE: currently this ignores the return type of gsl_rng_memcpy since
// I don't know what it does (the manual is quiet on that)
func (s *RngState) Memcpy(dest RngState) {
	C.gsl_rng_memcpy(dest.state, s.state)
}
예제 #2
0
파일: rng.go 프로젝트: postfix/gsl-1
func Memcpy(dest *GslRng, src *GslRng) int32 {
	return int32(C.gsl_rng_memcpy((*C.gsl_rng)(unsafe.Pointer(dest.Ptr())), (*C.gsl_rng)(unsafe.Pointer(src.Ptr()))))
}