diff options
Diffstat (limited to 'stdlib/source/lux/type/abstract.lux')
-rw-r--r-- | stdlib/source/lux/type/abstract.lux | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/stdlib/source/lux/type/abstract.lux b/stdlib/source/lux/type/abstract.lux index 8d20c25c5..cf6f1b4e4 100644 --- a/stdlib/source/lux/type/abstract.lux +++ b/stdlib/source/lux/type/abstract.lux @@ -63,8 +63,8 @@ (do macro.Monad<Meta> [this-module (macro.find-module this-module-name) #let [type-varsC (list/map code.local-symbol type-vars) - abstract-declaration (` ((~ (code.local-symbol name)) (~@ type-varsC))) - representation-declaration (` ((~ (code.local-symbol (representation-name name))) (~@ type-varsC))) + abstract-declaration (` ((~ (code.local-symbol name)) (~+ type-varsC))) + representation-declaration (` ((~ (code.local-symbol (representation-name name))) (~+ type-varsC))) this-module (|> this-module (update@ #.defs (put down-cast (: Def [Macro macro-anns @@ -72,7 +72,7 @@ (function [tokens] (case tokens (^ (list value)) - (wrap (list (` ((: (All [(~@ type-varsC)] + (wrap (list (` ((: (All [(~+ type-varsC)] (-> (~ representation-declaration) (~ abstract-declaration))) (|>> :!!)) (~ value))))) @@ -85,7 +85,7 @@ (function [tokens] (case tokens (^ (list value)) - (wrap (list (` ((: (All [(~@ type-varsC)] + (wrap (list (` ((: (All [(~+ type-varsC)] (-> (~ abstract-declaration) (~ representation-declaration))) (|>> :!!)) (~ value))))) @@ -107,8 +107,8 @@ (#E.Success [(update@ #.modules (put this-module-name this-module) compiler) []])))) -(syntax: #hidden (install-casts [name s.local-symbol] - [type-vars (s.tuple (p.some s.local-symbol))]) +(syntax: (install-casts [name s.local-symbol] + [type-vars (s.tuple (p.some s.local-symbol))]) (do @ [this-module-name macro.current-module-name ?down-cast (macro.find-macro [this-module-name down-cast]) @@ -125,7 +125,7 @@ down-cast " & " up-cast ") because definitions like that already exist."))))) -(syntax: #hidden (un-install-casts) +(syntax: (un-install-casts) (do macro.Monad<Meta> [this-module-name macro.current-module-name ?down-cast (macro.find-macro [this-module-name down-cast]) @@ -154,13 +154,13 @@ [primitives (p.some s.any)]) (let [hidden-name (representation-name name) type-varsC (list/map code.local-symbol type-vars) - abstract-declaration (` ((~ (code.local-symbol name)) (~@ type-varsC))) - representation-declaration (` ((~ (code.local-symbol hidden-name)) (~@ type-varsC)))] - (wrap (list& (` (type: (~@ (csw.export export)) (~ abstract-declaration) + abstract-declaration (` ((~ (code.local-symbol name)) (~+ type-varsC))) + representation-declaration (` ((~ (code.local-symbol hidden-name)) (~+ type-varsC)))] + (wrap (list& (` (type: (~+ (csw.export export)) (~ abstract-declaration) (~ (csw.annotations annotations)) - (primitive (~ (code.text hidden-name)) [(~@ type-varsC)]))) - (` (type: (~@ (csw.export export)) (~ representation-declaration) + (primitive (~ (code.text hidden-name)) [(~+ type-varsC)]))) + (` (type: (~+ (csw.export export)) (~ representation-declaration) (~ representation-type))) - (` (install-casts (~ (code.local-symbol name)) [(~@ type-varsC)])) + (` ((~! install-casts) (~ (code.local-symbol name)) [(~+ type-varsC)])) (list/compose primitives - (list (` (un-install-casts)))))))) + (list (` ((~! un-install-casts))))))))) |