diff options
Diffstat (limited to 'core/metaprogramming.nom')
| -rw-r--r-- | core/metaprogramming.nom | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/core/metaprogramming.nom b/core/metaprogramming.nom index be7450a..2ae8b1b 100644 --- a/core/metaprogramming.nom +++ b/core/metaprogramming.nom @@ -71,9 +71,8 @@ lua> "\ if \%body.type == "Text" then \%body = SyntaxTree{source=\%body.source, type="Action", "Lua", \%body} end - local lua = LuaCode(tree.source, "compile.action[", \%action.stub:as_lua(), + return LuaCode(tree.source, "compile.action[", \%action.stub:as_lua(), "] = ", \(what (%args -> %body) compiles to)) - return lua end" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -332,7 +331,7 @@ test: ..one "two"" ..== "\"one\\n\\\"two\\\"\"" -(quote %s) compiles to (Lua "tostring(\(%s as lua expr)):as_lua()") +(quote %s) compiles to "tostring(\(%s as lua expr)):as_lua()" test: assume (lua type of {}) == "table" |
