aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/test/lux/macro/template.lux
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib/source/test/lux/macro/template.lux')
-rw-r--r--stdlib/source/test/lux/macro/template.lux19
1 files changed, 10 insertions, 9 deletions
diff --git a/stdlib/source/test/lux/macro/template.lux b/stdlib/source/test/lux/macro/template.lux
index 771c9c082..715a0dbe2 100644
--- a/stdlib/source/test/lux/macro/template.lux
+++ b/stdlib/source/test/lux/macro/template.lux
@@ -13,7 +13,7 @@
[collection
["[0]" list]]]
["[0]" macro (.only)
- [syntax (.only syntax:)]
+ [syntax (.only syntax)]
["[0]" code]]
[math
["[0]" random (.only Random)]
@@ -28,14 +28,15 @@
(-> Nat Nat)
(|>> !pow/2)))
-(syntax: (macro_error [macro <code>.any])
- (function (_ compiler)
- (case ((macro.expansion macro) compiler)
- {try.#Failure error}
- {try.#Success [compiler (list (code.text error))]}
-
- {try.#Success _}
- {try.#Failure "OOPS!"})))
+(def: macro_error
+ (syntax (_ [macro <code>.any])
+ (function (_ compiler)
+ (case ((macro.expansion macro) compiler)
+ {try.#Failure error}
+ {try.#Success [compiler (list (code.text error))]}
+
+ {try.#Success _}
+ {try.#Failure "OOPS!"}))))
(def: .public test
Test