github.com/primecitizens/pcz/std@v0.2.1/core/emu64/emu64_native.go (about) 1 // SPDX-License-Identifier: Apache-2.0 2 // Copyright 2023 The Prime Citizens 3 4 //go:build !(arm || 386 || mips || mipsle) 5 6 package emu64 7 8 func Float64ToInt64(n float64) uint64 { return uint64(n) } 9 func Float64ToUint64(n float64) uint64 { return uint64(n) } 10 func Int64ToFloat64(n int64) float64 { return float64(n) } 11 func Uint64ToFloat64(n uint64) float64 { return float64(n) } 12 func Int64ToFloat32(n int64) float32 { return float32(n) } 13 func Uint64ToFloat32(n uint64) float32 { return float32(n) } 14 func Uint64Div(n, d uint64) uint64 { return n / d } 15 func Uint64Mod(n, d uint64) uint64 { return n % d } 16 func Int64Div(n, d int64) int64 { return n / d } 17 func Int64Mod(n, d int64) int64 { return n % d } 18 func Float64ToUint32(n float64) uint32 { return uint32(n) } 19 func Uint32ToFloat64(n uint32) float64 { return float64(n) }