Skip to main content

nanvm_demos/gen.samples/
numbers.rs

1// @generated by `fjs compile`. Do not edit: recompile the source module instead.
2
3use nanvm_lib::vm::unstable::{f64_any, string_key};
4use nanvm_lib::vm::{Any, Array, IStaticFunction, ToAny, ToArray, ToObject};
5
6#[rustfmt::skip]
7#[allow(clippy::if_same_then_else)]
8pub fn module<A: IStaticFunction>(_runtime: Any<A>) -> Result<Any<A>, Any<A>> {
9    Ok([(string_key("default"), A::static_function(|_self, _args| {
10        let _b264: Any<A> = _args.rest(0).to_any();
11        (Any::dot([f64_any(0x0000000000000000), f64_any(0xc045400000000000), f64_any(0x4072c00000000000), f64_any(0x3e7ad7f29abcaf48)].to_array().to_any(), (Any::number((Any::dot(_b264.clone(), f64_any(0x0000000000000000)).end())?))?).end())? * f64_any(0x4000000000000000)
12    }, 0, Array::default(), Some("(...$0)=>[0,-42.5,300,1e-7][Number($0[0])]*2")).to_any())].to_object().to_any())
13}