lambda and if-number }:3
build / build (push) Successful in 38s

This commit is contained in:
2026-07-18 17:12:55 -06:00
parent 530a6934ba
commit 6774c08efb
18 changed files with 508 additions and 109 deletions
+10 -3
View File
@@ -5,11 +5,18 @@
(func $gh-write (param (ref eq))))
(import
"gyehoek"
"to-bool"
(func $gh-to-bool (param (ref eq)) (result i32)))
"truthy?"
(func $gh-truthy? (param (ref eq)) (result i32)))
(type $heap-object (sub (struct (field $hash (mut i32)))))
(type $cont-type (func (param i32)))
(type $cont-stack-type (array (mut (ref null $cont-type))))
(type
$closure
(sub
$heap-object
(struct
(field $hash (mut i32))
(field $code (ref $cont-type)))))
(global $cont-stack-top (mut i32) (i32.const 0))
(global
$cont-stack
@@ -35,7 +42,7 @@
(local (ref eq) (ref eq) (ref eq) (ref eq) (ref eq))
(i32.const 1)
ref.i31
(call $gh-to-bool)
(call $gh-truthy?)
(if
(then
(global.get $arg-array)