aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/library/lux/macro/local.lux
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib/source/library/lux/macro/local.lux')
-rw-r--r--stdlib/source/library/lux/macro/local.lux10
1 files changed, 5 insertions, 5 deletions
diff --git a/stdlib/source/library/lux/macro/local.lux b/stdlib/source/library/lux/macro/local.lux
index 67434aa09..03eab5adc 100644
--- a/stdlib/source/library/lux/macro/local.lux
+++ b/stdlib/source/library/lux/macro/local.lux
@@ -38,7 +38,7 @@
(#.Some module)
(case (body module)
(#try.Success [module' output])
- (#try.Success [(update@ #.modules (plist.put name module') compiler)
+ (#try.Success [(update@ #.modules (plist.has name module') compiler)
output])
(#try.Failure error)
@@ -53,7 +53,7 @@
[[module_name definition_name] (meta.normal name)
.let [definition (: Global (#.Definition [false .Macro (' {}) macro]))
add_macro! (: (-> (PList Global) (PList Global))
- (plist.put definition_name definition))]]
+ (plist.has definition_name definition))]]
(..with_module module_name
(function (_ module)
(case (|> module (get@ #.definitions) (plist.get definition_name))
@@ -68,13 +68,13 @@
(-> Name (Meta Any))
(do meta.monad
[[module_name definition_name] (meta.normal name)
- .let [remove_macro! (: (-> (PList Global) (PList Global))
- (plist.remove definition_name))]]
+ .let [lacks_macro! (: (-> (PList Global) (PList Global))
+ (plist.lacks definition_name))]]
(..with_module module_name
(function (_ module)
(case (|> module (get@ #.definitions) (plist.get definition_name))
(#.Some _)
- (#try.Success [(update@ #.definitions remove_macro! module)
+ (#try.Success [(update@ #.definitions lacks_macro! module)
[]])
#.None