MCPcopy Create free account
hub / github.com/GamerHack/GamerHack.github.io / lohi_from_one

Function lohi_from_one

g2all/900/module/int64.js:28–38  ·  view source on GitHub ↗
(low)

Source from the content-addressed store, hash-verified

26// their low/high bits. creating a Int is slower compared to just using this
27// function
28export function lohi_from_one(low) {
29 if (low instanceof Int) {
30 return low._u32.slice();
31 }
32
33 if (check_not_in_range(low)) {
34 throw TypeError(`low not a 32-bit integer: ${low}`);
35 }
36
37 return [low >>> 0, low < 0 ? -1 >>> 0 : 0];
38}
39
40// immutable 64-bit integer
41export class Int {

Callers 15

setMethod · 0.90
setMethod · 0.90
add_and_set_addrFunction · 0.90
cpyMethod · 0.90
fakeobjMethod · 0.90
set_addrMethod · 0.90
write64Method · 0.90
write64_atMethod · 0.90
retvalMethod · 0.90
retval_allMethod · 0.90
push_valueMethod · 0.90
write64Method · 0.90

Calls 1

check_not_in_rangeFunction · 0.70

Tested by

no test coverage detected