diff options
author | Eduardo Julian | 2019-06-20 22:32:59 -0400 |
---|---|---|
committer | Eduardo Julian | 2019-06-20 22:32:59 -0400 |
commit | b71b861008381626633bf28b033cd866d7e4e0b7 (patch) | |
tree | 3ee21cd21e6dd80f6fcdf90173bbd6162b616d8f /stdlib/source/lux/macro/poly/functor.lux | |
parent | fcee38da766a683ed5569978be153c6e7a8ae0af (diff) |
Improved the convention for using text formatters.
Diffstat (limited to '')
-rw-r--r-- | stdlib/source/lux/macro/poly/functor.lux | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/stdlib/source/lux/macro/poly/functor.lux b/stdlib/source/lux/macro/poly/functor.lux index 0de5009fd..e7a7c8b4a 100644 --- a/stdlib/source/lux/macro/poly/functor.lux +++ b/stdlib/source/lux/macro/poly/functor.lux @@ -10,7 +10,7 @@ [data ["." product] ["." text - format] + ["%" format (#+ format)]] [collection ["." list ("#;." monad monoid)]]] ["." macro @@ -34,7 +34,7 @@ (function (_ unwrappedT) (if (n/= 1 num-vars) (` ((~! functor.Functor) (~ (poly.to-code *env* unwrappedT)))) - (let [paramsC (|> num-vars dec list.indices (list;map (|>> %n code.local-identifier)))] + (let [paramsC (|> num-vars dec list.indices (list;map (|>> %.nat code.local-identifier)))] (` (All [(~+ paramsC)] ((~! functor.Functor) ((~ (poly.to-code *env* unwrappedT)) (~+ paramsC))))))))) Arg<?> (: (-> Code (<type>.Parser Code)) @@ -60,7 +60,7 @@ (<type>.tuple (loop [idx 0 pairsCC (: (List [Code Code]) (list))] - (p.either (let [slotC (|> idx %n (format "____________slot") code.local-identifier)] + (p.either (let [slotC (|> idx %.nat (format "____________slot") code.local-identifier)] (do @ [_ (wrap []) memberC (Arg<?> slotC)] @@ -79,7 +79,7 @@ (Arg<?> outL)) #let [inC+ (|> (list.size inT+) list.indices - (list;map (|>> %n (format "____________inC") code.local-identifier)))]] + (list;map (|>> %.nat (format "____________inC") code.local-identifier)))]] (wrap (` (function ((~ g!) (~+ inC+)) (let [(~ outL) ((~ valueC) (~+ inC+))] (~ outC)))))) @@ -95,7 +95,7 @@ [_ _ outputC] (: (<type>.Parser [Code (List Code) Code]) (p.either (<type>.polymorphic (Arg<?> inputC)) - (p.fail (format "Cannot create Functor for: " (%type inputT)))))] + (p.fail (format "Cannot create Functor for: " (%.type inputT)))))] (wrap (` (: (~ (@Functor inputT)) (structure (def: ((~' map) (~ funcC) (~ inputC)) (~ outputC)))))))) |