JSTQL-JS-Transform/output_testing/1126alias-capture-in-method-receiver-and-mutate.js

15 lines
404 B
JavaScript
Raw Normal View History

import { makeObject_Primitives, mutate } from "shared-runtime";
function Component() {
// a's mutable range should be the same as x's mutable range,
// since a is captured into x (which gets mutated later)
let a = makeObject_Primitives();
let x = [];
a |> x.push(%);
x |> mutate(%);
return [x, a];
}
export const FIXTURE_ENTRYPOINT = {
fn: Component,
params: [],
isComponent: false
};