From 825b5d96f8a0d146615f0c6a76feab46da9baa60 Mon Sep 17 00:00:00 2001 From: Li Jin Date: Mon, 22 Nov 2021 10:05:39 +0800 Subject: update macro spec and builtin Lua. --- spec/inputs/macro.yue | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) (limited to 'spec/inputs/macro.yue') diff --git a/spec/inputs/macro.yue b/spec/inputs/macro.yue index 366a3d9..2742bd0 100644 --- a/spec/inputs/macro.yue +++ b/spec/inputs/macro.yue @@ -6,6 +6,8 @@ import "macro-export" as { $config:$myconfig, -- rename macro $config to $myconfig } +import "macro-todo" as $ + $asserts item == nil $myconfig false @@ -258,19 +260,6 @@ print $tb[1], $tb.a, ($tb)!, $tb! print "current line: #{ $LINE }" -macro todoInner = (module, line, msg)-> - print "TODO#{msg and ': ' .. msg or ''} in file #{module}, at line #{line}" - { - code: "-- TODO#{msg and ': ' .. msg or ''}" - type: "lua" - } - -macro todo = (msg)-> - if msg - "$todoInner $MODULE, $LINE, #{msg}" - else - "$todoInner $MODULE, $LINE" - $todo macro implicitReturnMacroIsAllowed = -> "print 'abc'\n123" -- cgit v1.2.3-55-g6feb