aboutsummaryrefslogtreecommitdiff
path: root/core/coroutines.nom
diff options
context:
space:
mode:
Diffstat (limited to 'core/coroutines.nom')
-rw-r--r--core/coroutines.nom14
1 files changed, 7 insertions, 7 deletions
diff --git a/core/coroutines.nom b/core/coroutines.nom
index d7d1db4..e7ec41e 100644
--- a/core/coroutines.nom
+++ b/core/coroutines.nom
@@ -1,4 +1,4 @@
-#!/usr/bin/env nomsu -V3.8.7.6
+#!/usr/bin/env nomsu -V4.8.8.6
#
This file defines the code that creates and manipulates coroutines
@@ -15,15 +15,15 @@ test:
for % in coroutine %co: %nums::add %
assume (%nums == [4, 5, 6, 6, 6]) or barf "Coroutine iteration failed"
compile [coroutine %body, generator %body] to (..)
- Lua value ".."
- (function()
+ Lua value "\
+ ..(function()
\(%body as lua statements)
- end)
+ end)"
compile [->] to (Lua value "coroutine.yield(true)")
compile [-> %] to (Lua value "coroutine.yield(true, \(% as lua expr))")
compile [for % in coroutine %co %body] to (..)
- Lua ".."
- for junk,\(% as lua expr) in coroutine.wrap(\(%co as lua expr)) do
+ Lua "\
+ ..for junk,\(% as lua expr) in coroutine.wrap(\(%co as lua expr)) do
\(%body as lua statements)
- end
+ end"