diff options
author | Eduardo Julian | 2021-08-26 02:34:05 -0400 |
---|---|---|
committer | Eduardo Julian | 2021-08-26 02:34:05 -0400 |
commit | e814f667aed509a70bd386dcd54628929134def4 (patch) | |
tree | 0a948502194c846a66396020420bd99c6c68370a /stdlib/source/library/lux/data | |
parent | b216900093c905b3b20dd45c69e577b192e2f7a3 (diff) |
"Interface" instead of "interface:", and "Rec" can be used in type definition.
Diffstat (limited to 'stdlib/source/library/lux/data')
6 files changed, 29 insertions, 25 deletions
diff --git a/stdlib/source/library/lux/data/collection/array.lux b/stdlib/source/library/lux/data/collection/array.lux index 1549bae80..73e8a209b 100644 --- a/stdlib/source/library/lux/data/collection/array.lux +++ b/stdlib/source/library/lux/data/collection/array.lux @@ -1,6 +1,6 @@ (.module: [library - [lux (#- list example) + [lux (#- list) ["@" target] [abstract [monoid (#+ Monoid)] diff --git a/stdlib/source/library/lux/data/collection/list.lux b/stdlib/source/library/lux/data/collection/list.lux index b40e94669..9ea9c3132 100644 --- a/stdlib/source/library/lux/data/collection/list.lux +++ b/stdlib/source/library/lux/data/collection/list.lux @@ -1,6 +1,6 @@ (.module: [library - [lux (#- example) + [lux #* ["@" target] [abstract [monoid (#+ Monoid)] diff --git a/stdlib/source/library/lux/data/collection/tree.lux b/stdlib/source/library/lux/data/collection/tree.lux index d3222b959..47a4c8957 100644 --- a/stdlib/source/library/lux/data/collection/tree.lux +++ b/stdlib/source/library/lux/data/collection/tree.lux @@ -39,8 +39,9 @@ {#value value #children children}) -(type: #rec Tree_Code - [Code (List Tree_Code)]) +(type: Tree_Code + (Rec Tree_Code + [Code (List Tree_Code)])) (def: tree^ (Parser Tree_Code) diff --git a/stdlib/source/library/lux/data/collection/tree/finger.lux b/stdlib/source/library/lux/data/collection/tree/finger.lux index b0dcece05..3f807f49f 100644 --- a/stdlib/source/library/lux/data/collection/tree/finger.lux +++ b/stdlib/source/library/lux/data/collection/tree/finger.lux @@ -20,15 +20,16 @@ #root (Or v [(Tree @ t v) (Tree @ t v)])}) - (interface: .public (Builder @ t) - (: (All [v] - (-> t v (Tree @ t v))) - leaf) - (: (All [v] - (-> (Tree @ t v) - (Tree @ t v) - (Tree @ t v))) - branch)) + (type: .public (Builder @ t) + (Interface + (: (All [v] + (-> t v (Tree @ t v))) + leaf) + (: (All [v] + (-> (Tree @ t v) + (Tree @ t v) + (Tree @ t v))) + branch))) (template [<name> <tag> <output>] [(def: .public <name> diff --git a/stdlib/source/library/lux/data/format/json.lux b/stdlib/source/library/lux/data/format/json.lux index 6582b7402..6aec38ce5 100644 --- a/stdlib/source/library/lux/data/format/json.lux +++ b/stdlib/source/library/lux/data/format/json.lux @@ -40,14 +40,15 @@ [String Text] ) -(type: .public #rec JSON - (Variant - (#Null Null) - (#Boolean Boolean) - (#Number Number) - (#String String) - (#Array (Row JSON)) - (#Object (Dictionary String JSON)))) +(type: .public JSON + (Rec JSON + (Variant + (#Null Null) + (#Boolean Boolean) + (#Number Number) + (#String String) + (#Array (Row JSON)) + (#Object (Dictionary String JSON))))) (template [<name> <type>] [(type: .public <name> diff --git a/stdlib/source/library/lux/data/format/xml.lux b/stdlib/source/library/lux/data/format/xml.lux index ef2c8e19a..9c29b086a 100644 --- a/stdlib/source/library/lux/data/format/xml.lux +++ b/stdlib/source/library/lux/data/format/xml.lux @@ -34,10 +34,11 @@ Attrs (dictionary.empty name.hash)) -(type: .public #rec XML - (Variant - (#Text Text) - (#Node Tag Attrs (List XML)))) +(type: .public XML + (Rec XML + (Variant + (#Text Text) + (#Node Tag Attrs (List XML))))) (def: namespace_separator ":") |