summaryrefslogtreecommitdiff
path: root/test.xy
diff options
context:
space:
mode:
authorThomas Voss <mail@thomasvoss.com> 2026-03-04 00:13:12 +0100
committerThomas Voss <mail@thomasvoss.com> 2026-03-04 00:13:12 +0100
commit4be26b845b8cfddfafa738f620a21894f65c4de6 (patch)
tree61bd43ff93f8d6e6892bf2c3b617c7cd67bc485b /test.xy
parentbb66e26e4fd766397bd0a32863f9d1ac3135744e (diff)
Big parser work + error recovery
Diffstat (limited to 'test.xy')
-rw-r--r--test.xy12
1 files changed, 4 insertions, 8 deletions
diff --git a/test.xy b/test.xy
index e8809df..c49d138 100644
--- a/test.xy
+++ b/test.xy
@@ -1,7 +1,7 @@
def puts = $foreign("puts", func(s ^u8));
/*
-def foo = func {
+def foo = func() {
let my_string =
\ This is my line
\ this is a second line
@@ -18,21 +18,17 @@ def foo = func {
* dst[i] = v[i] + u[i];
* }; */
-def main′ = func {
- def foo, bar, baz;
+def main′ = func() {
puts("Hello, sailor!");
- 69 + ~420
some_func(#b10.1100'1001e+11);
- return 5
+ x, y = 69, 420;
slices_sort(my_slice, func(x, y int) int {
return x - y;
});
};
-69'420 - one;
def some_func = func(n u32) u32 { return n * 2; };
/* def MY_FLOAT = union { f f64; n u64; } { n = 0x482DEF }.f */
-def main = func { main′(); };
- foobar
+def main = func() { main′(); };