Skip to main content

nanvm_harness/gen.fixtures/
object_entries.rs

1// @generated by `fjs compile`. Do not edit: recompile the source module instead.
2
3use nanvm_lib::vm::unstable::{
4    bigint_any, f64_any, static_read, strict_eq, string_any, string_key,
5};
6use nanvm_lib::vm::{Any, Array, IStaticFunction, Nullish, Object, ToAny, ToArray, ToObject};
7
8#[rustfmt::skip]
9#[allow(clippy::if_same_then_else)]
10pub fn module<A: IStaticFunction>(runtime: Any<A>) -> Result<Any<A>, Any<A>> {
11    let _b7: Any<A> = (static_read(&runtime, "Object.entries"))?;
12    let _b15: Any<A> = A::static_function(|_self, _args| { static_read(&A::frame(_self)[0], "Object.entries") }, 0, [runtime.clone()].to_array(), Some("()=>Object.entries")).to_any();
13    Ok([(string_key("default"), {
14        let _b6: Any<A> = [[(string_key("b"), f64_any(0x3ff0000000000000)), (string_key("10"), f64_any(0x4000000000000000)), (string_key("2"), f64_any(0x4008000000000000)), (string_key("b"), f64_any(0x4010000000000000)), (string_key("u"), Nullish::Undefined.to_any())].to_object().to_any(), [f64_any(0x401c000000000000), [f64_any(0x4020000000000000)].to_array().to_any()].to_array().to_any(), string_any("a😀"), string_any(""), f64_any(0x3ff0000000000000), true.to_any(), bigint_any(1), A::static_function(|_self, _args| { Ok(f64_any(0x0000000000000000)) }, 0, [runtime.clone()].to_array(), Some("()=>0")).to_any(), Object::default().to_any()].to_array().to_any();
15        [(Any::dot(_b6.clone(), string_any("map")).end_call(&runtime, || Ok([A::static_function(|_self, _args| { Any::call(A::frame(_self)[0].clone(), [_args.argument(0)].to_array().to_any()) }, 1, [_b7.clone(), runtime.clone()].to_array(), Some("($1)=>$0($1)")).to_any()].to_array().to_any())))?, (Any::dot(_b6.clone(), string_any("map")).end_call(&runtime, || Ok([_b7.clone()].to_array().to_any())))?, [(strict_eq((Any::call(_b15.clone(), Array::default().to_any()))?, (Any::call(_b15.clone(), Array::default().to_any()))?))?, (strict_eq(_b7.clone(), (static_read(&runtime, "Object.entries"))?))?, (strict_eq(_b7.clone(), (static_read(&runtime, "Object.entries"))?))?, (Any::typeof_((static_read(&runtime, "Object.entries"))?))?, (Any::dot((static_read(&runtime, "Object.entries"))?, string_any("length")).end())?, ((static_read(&runtime, "Object.entries"))?.to_string().map(|v| v.to_any()))?].to_array().to_any(), {
16            let _b30: Any<A> = [(string_key("a"), f64_any(0x3ff0000000000000))].to_object().to_any();
17            [(strict_eq((Any::call(_b7.clone(), [_b30.clone()].to_array().to_any()))?, (Any::call(_b7.clone(), [_b30.clone()].to_array().to_any()))?))?, (strict_eq((Any::dot((Any::call(_b7.clone(), [_b30.clone()].to_array().to_any()))?, f64_any(0x0000000000000000)).end())?, (Any::dot((Any::call(_b7.clone(), [_b30.clone()].to_array().to_any()))?, f64_any(0x0000000000000000)).end())?))?].to_array().to_any()
18        }].to_array().to_any()
19    })].to_object().to_any())
20}