aboutsummaryrefslogtreecommitdiff
path: root/src/z/js/parser/test_fixture.js
diff options
context:
space:
mode:
authorNathan Reiner <nathan@nathanreiner.xyz>2026-07-30 09:36:34 +0200
committerNathan Reiner <nathan@nathanreiner.xyz>2026-07-30 09:36:34 +0200
commitaca38f5c96709f56db75a476051eb644de644d3d (patch)
tree1ce90ccffb80cff8d527be6efbd073031fccd3a1 /src/z/js/parser/test_fixture.js
parent006674d7e08146a9bd980e2138ce9444d2e40e6f (diff)
restructure project
Diffstat (limited to 'src/z/js/parser/test_fixture.js')
-rw-r--r--src/z/js/parser/test_fixture.js86
1 files changed, 0 insertions, 86 deletions
diff --git a/src/z/js/parser/test_fixture.js b/src/z/js/parser/test_fixture.js
deleted file mode 100644
index 378ceb3..0000000
--- a/src/z/js/parser/test_fixture.js
+++ /dev/null
@@ -1,86 +0,0 @@
-#!/usr/bin/env node
-// comment line
-/* block
- comment */
-var x = 42;
-let y = "hello";
-const z = `template ${x} literal`;
-let a = 0b1010;
-let b = 0xFF;
-let c = 0o77;
-let d = 123n;
-let e = /pattern/gi;
-let f = true;
-let g = null;
-function hello(a, b) {
- if (a > b) {
- return a;
- } else {
- return b;
- }
-}
-const arrow = (x) => x * 2;
-const obj = {
- a: 1,
- b: "two",
- c,
- [d]: 4,
- method() { return 5; },
- get prop() { return 6; },
- set prop(v) { },
-};
-const arr = [1, 2, ...rest, 4];
-for (var i = 0; i < 10; i++) {
- continue;
-}
-for (const key in obj) {
- break;
-}
-for (const val of arr) {
- ;
-}
-while (x < 10) {
- x++;
-}
-do {
- x--;
-} while (x > 0);
-try {
- throw "err";
-} catch (e) {
- console.log(e);
-} finally {
- cleanup();
-}
-switch (x) {
- case 1:
- break;
- case 2:
- return;
- default:
- break;
-}
-class Foo extends Bar {
- constructor() { super(); }
- static method() { }
- get prop() { return 1; }
- set prop(v) { }
-}
-const { a: p, b: q } = obj;
-const [head, ...tail] = arr;
-import { something } from "module";
-export default x;
-export const named = 1;
-export function exported() { }
-import "side-effect";
-import * as ns from "module";
-export { x as y } from "module";
-export * from "module";
-delete obj.a;
-typeof x;
-void x;
-x ?? y;
-x?.y?.z;
-x ??= y;
-x &&= y;
-x ||= y;