From b54829de363f67a8a6f6131ceb0eb27aa09d4292 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Fri, 27 Apr 2018 16:45:11 -0700 Subject: Better text interpolation/handling of "\". Also added syntax support for (statement; statement) --- core/metaprogramming.nom | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'core/metaprogramming.nom') diff --git a/core/metaprogramming.nom b/core/metaprogramming.nom index e967172..fdbae61 100644 --- a/core/metaprogramming.nom +++ b/core/metaprogramming.nom @@ -13,7 +13,7 @@ immediately end stubs = repr(stubs); if #stubs > 80 then - lua:append("\\n ",stubs,",\\n "); + lua:append("\n ",stubs,",\n "); else lua:append(stubs,", "); end @@ -30,7 +30,7 @@ immediately body_lua:convert_to_statements("return "); body_lua:remove_free_vars(unpack(args)); body_lua:declare_locals(); - lua:append(")\\n ", body_lua, "\\nend);"); + lua:append(")\n ", body_lua, "\nend);"); return lua; end); @@ -45,7 +45,7 @@ immediately end stubs = repr(stubs); if #stubs > 80 then - lua:append("\\n ",stubs,",\\n "); + lua:append("\n ",stubs,",\n "); else lua:append(stubs,", "); end @@ -62,7 +62,7 @@ immediately body_lua:convert_to_statements("return "); body_lua:remove_free_vars(unpack(args)); body_lua:declare_locals(); - lua:append(")\\n ", body_lua, "\\nend);") + lua:append(")\n ", body_lua, "\nend);") return lua; # Macro to make nomsu macros @@ -76,7 +76,7 @@ immediately end stubs = repr(stubs); if #stubs > 80 then - lua:append("\\n ",stubs,",\\n "); + lua:append("\n ",stubs,",\n "); else lua:append(stubs,", "); end -- cgit v1.2.3