diff options
author | Eduardo Julian | 2019-02-04 19:38:19 -0400 |
---|---|---|
committer | Eduardo Julian | 2019-02-04 19:38:19 -0400 |
commit | cb4beecbbc4ab3ec918ab640ffb621036707678f (patch) | |
tree | 5c6351067aad4d29f4dca059cbc3e69862ad2dde /stdlib/source | |
parent | 41d34484cf6e0123bc8152251650423a6c8ba098 (diff) |
Fixed a bug in how the "_$" macro works.
Diffstat (limited to '')
-rw-r--r-- | stdlib/source/lux.lux | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/stdlib/source/lux.lux b/stdlib/source/lux.lux index 334632272..1a35b4ebd 100644 --- a/stdlib/source/lux.lux +++ b/stdlib/source/lux.lux @@ -1574,6 +1574,13 @@ (form$ (list op a1 a2))} op)) +(def:''' (function/flip func) + #Nil + (All [a b c] + (-> (-> a b c) (-> b a c))) + (function' [right left] + (func left right))) + (macro:' #export (_$ tokens) (#Cons [(tag$ ["lux" "doc"]) (text$ ("lux text concat" @@ -1586,7 +1593,7 @@ #Nil) ({(#Cons op tokens') ({(#Cons first nexts) - (return (list (list/fold (_$_joiner op) first nexts))) + (return (list (list/fold (function/flip (_$_joiner op)) first nexts))) _ (fail "Wrong syntax for _$")} |