diff options
Diffstat (limited to 'stdlib/source/library')
85 files changed, 182 insertions, 177 deletions
diff --git a/stdlib/source/library/lux/control/concurrency/actor.lux b/stdlib/source/library/lux/control/concurrency/actor.lux index 55534dfab..fc2033517 100644 --- a/stdlib/source/library/lux/control/concurrency/actor.lux +++ b/stdlib/source/library/lux/control/concurrency/actor.lux @@ -14,7 +14,7 @@ [macro ["[0]" local]] [type (.only sharing) - [primitive (.only primitive: representation abstraction)]]]] + [primitive (.only primitive representation abstraction)]]]] [// ["[0]" atom (.only Atom atom)] ["[0]" async (.only Async Resolver)] @@ -47,7 +47,7 @@ {.#None} (in {.#End})))) - (primitive: .public (Actor s) + (primitive .public (Actor s) (Record [#obituary [(Async (<Obituary> Actor s)) (Resolver (<Obituary> Actor s))] diff --git a/stdlib/source/library/lux/control/concurrency/async.lux b/stdlib/source/library/lux/control/concurrency/async.lux index 0770db384..20fabdb3b 100644 --- a/stdlib/source/library/lux/control/concurrency/async.lux +++ b/stdlib/source/library/lux/control/concurrency/async.lux @@ -21,7 +21,7 @@ ["[0]" thread] ["[0]" atom (.only Atom atom)]]) -(primitive: .public (Async'' a) +(primitive .public (Async'' a) (Atom [(Maybe a) (List (-> a (IO Any)))]) (type: .public (Async' r w) diff --git a/stdlib/source/library/lux/control/concurrency/atom.lux b/stdlib/source/library/lux/control/concurrency/atom.lux index e14e86c01..86399e1a6 100644 --- a/stdlib/source/library/lux/control/concurrency/atom.lux +++ b/stdlib/source/library/lux/control/concurrency/atom.lux @@ -26,7 +26,7 @@ @.jvm <jvm> (these))) -(primitive: .public (Atom'' a) +(primitive .public (Atom'' a) (with_expansions [<jvm> (java/util/concurrent/atomic/AtomicReference a)] (for @.old <jvm> @.jvm <jvm> diff --git a/stdlib/source/library/lux/control/concurrency/semaphore.lux b/stdlib/source/library/lux/control/concurrency/semaphore.lux index 3c6deadeb..5cf050d4b 100644 --- a/stdlib/source/library/lux/control/concurrency/semaphore.lux +++ b/stdlib/source/library/lux/control/concurrency/semaphore.lux @@ -30,7 +30,7 @@ #open_positions Int #waiting_list (Queue (Resolver Any))])) -(primitive: .public Semaphore +(primitive .public Semaphore (Atom State) (def: most_positions_possible @@ -94,7 +94,7 @@ (in {try.#Success (the #open_positions post)}))))))) ) -(primitive: .public Mutex +(primitive .public Mutex Semaphore (def: .public (mutex _) @@ -124,7 +124,7 @@ (type: .public Limit (~ (refinement.type limit))) -(primitive: .public Barrier +(primitive .public Barrier (Record [#limit Limit #count (Atom Nat) diff --git a/stdlib/source/library/lux/control/concurrency/stm.lux b/stdlib/source/library/lux/control/concurrency/stm.lux index 3d16d8338..c5323c442 100644 --- a/stdlib/source/library/lux/control/concurrency/stm.lux +++ b/stdlib/source/library/lux/control/concurrency/stm.lux @@ -26,7 +26,7 @@ (type: (Observer a) (-> a (IO Any))) -(primitive: .public (Var'' a) +(primitive .public (Var'' a) (Atom [a (List (Sink a))]) (type: .public (Var' r w) diff --git a/stdlib/source/library/lux/control/io.lux b/stdlib/source/library/lux/control/io.lux index a942a7c80..0b2372c6b 100644 --- a/stdlib/source/library/lux/control/io.lux +++ b/stdlib/source/library/lux/control/io.lux @@ -14,7 +14,7 @@ [syntax (.only syntax)] ["[0]" template]]]]) -(primitive: .public (IO a) +(primitive .public (IO a) (-> Any a) (def: label diff --git a/stdlib/source/library/lux/control/lazy.lux b/stdlib/source/library/lux/control/lazy.lux index 62baa0ec1..c96a5f569 100644 --- a/stdlib/source/library/lux/control/lazy.lux +++ b/stdlib/source/library/lux/control/lazy.lux @@ -17,7 +17,7 @@ [type (.only sharing) [primitive (.except)]]]]) -(primitive: .public (Lazy a) +(primitive .public (Lazy a) (-> [] a) (def: (lazy' generator) diff --git a/stdlib/source/library/lux/control/security/capability.lux b/stdlib/source/library/lux/control/security/capability.lux index 90c98a89e..482f61161 100644 --- a/stdlib/source/library/lux/control/security/capability.lux +++ b/stdlib/source/library/lux/control/security/capability.lux @@ -23,7 +23,7 @@ ["|[0]|" export] ["|[0]|" declaration]]]]]) -(primitive: .public (Capability brand input output) +(primitive .public (Capability brand input output) (-> input output) (def: capability diff --git a/stdlib/source/library/lux/control/security/policy.lux b/stdlib/source/library/lux/control/security/policy.lux index 2328915f6..f8856c593 100644 --- a/stdlib/source/library/lux/control/security/policy.lux +++ b/stdlib/source/library/lux/control/security/policy.lux @@ -8,7 +8,7 @@ [type [primitive (.except)]]]]) -(primitive: .public (Policy brand value label) +(primitive .public (Policy brand value label) value (type: .public (Can_Upgrade brand label value) @@ -77,7 +77,7 @@ ) (with_template [<brand> <value> <upgrade> <downgrade>] - [(primitive: .public <brand> + [(primitive .public <brand> Any (type: .public <value> diff --git a/stdlib/source/library/lux/control/thread.lux b/stdlib/source/library/lux/control/thread.lux index 2725e4a84..bb48b31b0 100644 --- a/stdlib/source/library/lux/control/thread.lux +++ b/stdlib/source/library/lux/control/thread.lux @@ -19,7 +19,7 @@ (type: .public (Thread ! a) (-> ! a)) -(primitive: .public (Box'' t a) +(primitive .public (Box'' t a) (Array a) (type: .public (Box' t r w) diff --git a/stdlib/source/library/lux/data/collection/queue/priority.lux b/stdlib/source/library/lux/data/collection/queue/priority.lux index f62ff3c6a..2cf313bec 100644 --- a/stdlib/source/library/lux/data/collection/queue/priority.lux +++ b/stdlib/source/library/lux/data/collection/queue/priority.lux @@ -14,7 +14,7 @@ [number ["n" nat (.open: "[1]#[0]" interval)]]] [type (.only by_example) - [primitive (.only primitive: abstraction representation)]]]]) + [primitive (.only primitive abstraction representation)]]]]) (type: .public Priority Nat) @@ -37,7 +37,7 @@ @)) -(primitive: .public (Queue a) +(primitive .public (Queue a) (Maybe (Tree :@: Priority a)) (def: .public empty diff --git a/stdlib/source/library/lux/data/collection/set/multi.lux b/stdlib/source/library/lux/data/collection/set/multi.lux index f43c6fa10..3e63b2926 100644 --- a/stdlib/source/library/lux/data/collection/set/multi.lux +++ b/stdlib/source/library/lux/data/collection/set/multi.lux @@ -14,13 +14,13 @@ [number ["n" nat]]] [type - ["[0]" primitive (.only primitive: abstraction representation)]]]] + ["[0]" primitive (.only primitive abstraction representation)]]]] ["[0]" // (.only) [// ["[0]" list (.open: "[1]#[0]" mix monoid)] ["[0]" dictionary (.only Dictionary)]]]) -(primitive: .public (Set a) +(primitive .public (Set a) (Dictionary a Nat) (def: .public empty diff --git a/stdlib/source/library/lux/data/collection/set/ordered.lux b/stdlib/source/library/lux/data/collection/set/ordered.lux index 30fab5b6a..c876afca0 100644 --- a/stdlib/source/library/lux/data/collection/set/ordered.lux +++ b/stdlib/source/library/lux/data/collection/set/ordered.lux @@ -12,7 +12,7 @@ [type [primitive (.except)]]]]) -(primitive: .public (Set a) +(primitive .public (Set a) (/.Dictionary a a) (def: .public empty diff --git a/stdlib/source/library/lux/data/collection/stack.lux b/stdlib/source/library/lux/data/collection/stack.lux index baf2bf038..086b727ca 100644 --- a/stdlib/source/library/lux/data/collection/stack.lux +++ b/stdlib/source/library/lux/data/collection/stack.lux @@ -10,7 +10,7 @@ [type [primitive (.except)]]]]) -(primitive: .public (Stack a) +(primitive .public (Stack a) (List a) (def: .public empty diff --git a/stdlib/source/library/lux/data/collection/tree/finger.lux b/stdlib/source/library/lux/data/collection/tree/finger.lux index b316d4dc5..0d8527308 100644 --- a/stdlib/source/library/lux/data/collection/tree/finger.lux +++ b/stdlib/source/library/lux/data/collection/tree/finger.lux @@ -8,10 +8,10 @@ [collection ["[0]" list (.open: "[1]#[0]" monoid)]]] [type - [primitive (.only primitive: abstraction representation)]]]]) + [primitive (.only primitive abstraction representation)]]]]) ... https://en.wikipedia.org/wiki/Finger_tree -(primitive: .public (Tree @ t v) +(primitive .public (Tree @ t v) (Record [#monoid (Monoid t) #tag t diff --git a/stdlib/source/library/lux/data/color.lux b/stdlib/source/library/lux/data/color.lux index c6d5126f0..2a89c02fe 100644 --- a/stdlib/source/library/lux/data/color.lux +++ b/stdlib/source/library/lux/data/color.lux @@ -51,7 +51,7 @@ (type: .public HSB [Frac Frac Frac]) -(primitive: .public Color +(primitive .public Color RGB (def: .public (of_rgb [red green blue]) diff --git a/stdlib/source/library/lux/data/format/css.lux b/stdlib/source/library/lux/data/format/css.lux index cbbc587c7..df39b6b61 100644 --- a/stdlib/source/library/lux/data/format/css.lux +++ b/stdlib/source/library/lux/data/format/css.lux @@ -24,10 +24,10 @@ ["[1][0]" style] ["[1][0]" query (.only Query)]]) -(primitive: .public Common Any) -(primitive: .public Special Any) +(primitive .public Common Any) +(primitive .public Special Any) -(primitive: .public (CSS brand) +(primitive .public (CSS brand) Text (def: .public css diff --git a/stdlib/source/library/lux/data/format/css/class.lux b/stdlib/source/library/lux/data/format/css/class.lux index 13fec00a4..1fb58b4d7 100644 --- a/stdlib/source/library/lux/data/format/css/class.lux +++ b/stdlib/source/library/lux/data/format/css/class.lux @@ -13,7 +13,7 @@ [type [primitive (.except)]]]]) -(primitive: .public Class +(primitive .public Class Text (def: .public class diff --git a/stdlib/source/library/lux/data/format/css/id.lux b/stdlib/source/library/lux/data/format/css/id.lux index 00f094c1a..2ba540356 100644 --- a/stdlib/source/library/lux/data/format/css/id.lux +++ b/stdlib/source/library/lux/data/format/css/id.lux @@ -13,7 +13,7 @@ [type [primitive (.except)]]]]) -(primitive: .public ID +(primitive .public ID Text (def: .public id diff --git a/stdlib/source/library/lux/data/format/css/property.lux b/stdlib/source/library/lux/data/format/css/property.lux index 9361d2d4a..21348e82d 100644 --- a/stdlib/source/library/lux/data/format/css/property.lux +++ b/stdlib/source/library/lux/data/format/css/property.lux @@ -58,7 +58,7 @@ (syntax (_ [symbol s.text]) (in (list (code.local (text.replaced "-" "_" symbol)))))) -(primitive: .public (Property brand) +(primitive .public (Property brand) Text (def: .public name diff --git a/stdlib/source/library/lux/data/format/css/query.lux b/stdlib/source/library/lux/data/format/css/query.lux index ea280933c..f4d2fccd5 100644 --- a/stdlib/source/library/lux/data/format/css/query.lux +++ b/stdlib/source/library/lux/data/format/css/query.lux @@ -25,7 +25,7 @@ (syntax (_ [symbol s.text]) (in (list (code.local (text.replaced "-" "_" symbol)))))) -(primitive: .public Media +(primitive .public Media Text (def: .public media @@ -43,7 +43,7 @@ ["speech"] )) -(primitive: .public Feature +(primitive .public Feature Text (def: .public feature @@ -103,7 +103,7 @@ ) ) -(primitive: .public Query +(primitive .public Query Text (def: .public query diff --git a/stdlib/source/library/lux/data/format/css/selector.lux b/stdlib/source/library/lux/data/format/css/selector.lux index ad025e3e9..2fe5ae11e 100644 --- a/stdlib/source/library/lux/data/format/css/selector.lux +++ b/stdlib/source/library/lux/data/format/css/selector.lux @@ -21,21 +21,21 @@ (type: .public Tag Label) (type: .public Attribute Label) -(primitive: .public (Generic brand) Any) +(primitive .public (Generic brand) Any) (with_template [<generic> <brand>] - [(primitive: <brand> Any) + [(primitive <brand> Any) (type: .public <generic> (Generic <brand>))] [Can_Chain Can_Chain'] [Cannot_Chain Cannot_Chain'] ) -(primitive: .public Unique Any) -(primitive: .public Specific Any) -(primitive: .public Composite Any) +(primitive .public Unique Any) +(primitive .public Specific Any) +(primitive .public Composite Any) -(primitive: .public (Selector kind) +(primitive .public (Selector kind) Text (def: .public selector @@ -167,7 +167,7 @@ (format ":not") abstraction)) - (primitive: .public Index + (primitive .public Index Text (def: .public index diff --git a/stdlib/source/library/lux/data/format/css/style.lux b/stdlib/source/library/lux/data/format/css/style.lux index 35348d5e7..eba1e112d 100644 --- a/stdlib/source/library/lux/data/format/css/style.lux +++ b/stdlib/source/library/lux/data/format/css/style.lux @@ -12,7 +12,7 @@ ["[1][0]" value (.only Value)] ["[1][0]" property (.only Property)]]) -(primitive: .public Style +(primitive .public Style Text (def: .public empty diff --git a/stdlib/source/library/lux/data/format/css/value.lux b/stdlib/source/library/lux/data/format/css/value.lux index e2bf08a20..66c82fe50 100644 --- a/stdlib/source/library/lux/data/format/css/value.lux +++ b/stdlib/source/library/lux/data/format/css/value.lux @@ -35,7 +35,7 @@ (def: enumeration (template (_ <abstraction> <representation> <out> <sample>+ <definition>+) - [(primitive: .public <abstraction> + [(primitive .public <abstraction> <representation> (def: .public <out> @@ -57,7 +57,7 @@ raw (|> raw (text.split_at 1) maybe.trusted product.right)))) -(primitive: .public (Value brand) +(primitive .public (Value brand) Text (def: .public value @@ -72,11 +72,11 @@ [unset "unset"] ) - (primitive: .public (Numeric kind) Any) + (primitive .public (Numeric kind) Any) (with_template [<name>] [(with_expansions [<name>' (template.symbol [<name> "'"])] - (primitive: .public <name>' Any) + (primitive .public <name>' Any) (type: .public <name> (Numeric <name>')))] @@ -87,7 +87,7 @@ ) (with_template [<brand> <alias>+ <value>+] - [(primitive: .public <brand> Any) + [(primitive .public <brand> Any) (`` (with_template [<name> <value>] [(def: .public <name> @@ -889,7 +889,7 @@ (abstraction (format (%.nat horizontal) ..slice_separator (%.nat vertical)))) - (primitive: .public Stop + (primitive .public Stop Text (def: .public stop @@ -909,7 +909,7 @@ (representation Value start) ..stop_separator (representation Value end)))) - (primitive: .public Hint + (primitive .public Hint Text (def: .public hint @@ -928,7 +928,7 @@ (type: .public (List/1 a) [a (List a)]) - (primitive: .public Angle + (primitive .public Angle Text (def: .public angle diff --git a/stdlib/source/library/lux/data/format/html.lux b/stdlib/source/library/lux/data/format/html.lux index 50b4d8de5..3a8bcd5c6 100644 --- a/stdlib/source/library/lux/data/format/html.lux +++ b/stdlib/source/library/lux/data/format/html.lux @@ -79,11 +79,11 @@ (-> Tag Text) (text.enclosed ["</" ">"])) -(primitive: .public (HTML brand) +(primitive .public (HTML brand) Text (.with_template [<name> <brand>] - [(primitive: <brand> Any) + [(primitive <brand> Any) (type: .public <name> (HTML <brand>))] [Meta Meta'] @@ -101,11 +101,11 @@ ) (.with_template [<super> <super_raw> <sub>+] - [(primitive: (<super_raw> brand) Any) + [(primitive (<super_raw> brand) Any) (type: .public <super> (HTML (<super_raw> Any))) (`` (.with_template [<sub> <sub_raw>] - [(primitive: <sub_raw> Any) + [(primitive <sub_raw> Any) (type: .public <sub> (HTML (<super_raw> <sub_raw>)))] (~~ (template.spliced <sub>+))))] diff --git a/stdlib/source/library/lux/data/format/markdown.lux b/stdlib/source/library/lux/data/format/markdown.lux index 1e2673a85..d65c5e6f6 100644 --- a/stdlib/source/library/lux/data/format/markdown.lux +++ b/stdlib/source/library/lux/data/format/markdown.lux @@ -31,10 +31,10 @@ (text.replaced "." "\.") (text.replaced "!" "\!"))) -(primitive: .public Span Any) -(primitive: .public Block Any) +(primitive .public Span Any) +(primitive .public Block Any) -(primitive: .public (Markdown brand) +(primitive .public (Markdown brand) Text (def: .public empty diff --git a/stdlib/source/library/lux/data/format/tar.lux b/stdlib/source/library/lux/data/format/tar.lux index 1c75474cf..272d666de 100644 --- a/stdlib/source/library/lux/data/format/tar.lux +++ b/stdlib/source/library/lux/data/format/tar.lux @@ -75,7 +75,7 @@ "Value" (%.nat value) "Maximum" (%.nat (-- <limit>)))) - (primitive: .public <type> + (primitive .public <type> Nat (def: .public (<in> value) @@ -160,7 +160,7 @@ [value (at n.octal decoded digits)] (..big value))))) -(primitive: Checksum +(primitive Checksum Text (def: from_checksum @@ -249,7 +249,7 @@ (binary!.slice 0 (++ end) string)))))))) (with_template [<type> <representation> <size> <exception> <in> <out> <writer> <parser> <none>] - [(primitive: .public <type> + [(primitive .public <type> <representation> (exception: .public (<exception> [value Text]) @@ -306,7 +306,7 @@ (def: magic_size Size 7) -(primitive: Magic +(primitive Magic Text (def: ustar @@ -393,7 +393,7 @@ ... devminor (..small_number ..device_size))) -(primitive: Link_Flag +(primitive Link_Flag Char (def: link_flag @@ -441,7 +441,7 @@ (exception.except ..invalid_link_flag [(.nat it)])))))) ) -(primitive: .public Mode +(primitive .public Mode Nat (def: .public mode @@ -529,7 +529,7 @@ (list.repeated ..content_size) (list#mix n.* 1))) -(primitive: .public Content +(primitive .public Content [Big Binary] (def: .public (content content) diff --git a/stdlib/source/library/lux/data/text/buffer.lux b/stdlib/source/library/lux/data/text/buffer.lux index 4559e04dd..a099758f5 100644 --- a/stdlib/source/library/lux/data/text/buffer.lux +++ b/stdlib/source/library/lux/data/text/buffer.lux @@ -48,7 +48,7 @@ ) (these)))) -(`` (primitive: .public Buffer +(`` (primitive .public Buffer (for @.old [Nat (-> java/lang/StringBuilder java/lang/StringBuilder)] @.jvm [Nat (-> java/lang/StringBuilder java/lang/StringBuilder)] @.js [Nat (-> (JS_Array Text) (JS_Array Text))] diff --git a/stdlib/source/library/lux/data/text/encoding.lux b/stdlib/source/library/lux/data/text/encoding.lux index da140a7e1..2863d9623 100644 --- a/stdlib/source/library/lux/data/text/encoding.lux +++ b/stdlib/source/library/lux/data/text/encoding.lux @@ -7,7 +7,7 @@ [primitive (.except)]]]]) ... https://en.wikipedia.org/wiki/Character_encoding#Common_character_encodings -(primitive: .public Encoding +(primitive .public Encoding Text (with_template [<name> <encoding>] diff --git a/stdlib/source/library/lux/data/text/unicode/block.lux b/stdlib/source/library/lux/data/text/unicode/block.lux index a95c2ad0a..7f3eeb32d 100644 --- a/stdlib/source/library/lux/data/text/unicode/block.lux +++ b/stdlib/source/library/lux/data/text/unicode/block.lux @@ -14,7 +14,7 @@ [primitive (.except)]]]] [/// (.only Char)]) -(primitive: .public Block +(primitive .public Block (Interval Char) (def: .public monoid diff --git a/stdlib/source/library/lux/data/text/unicode/set.lux b/stdlib/source/library/lux/data/text/unicode/set.lux index 92a575201..fdbf1955a 100644 --- a/stdlib/source/library/lux/data/text/unicode/set.lux +++ b/stdlib/source/library/lux/data/text/unicode/set.lux @@ -26,7 +26,7 @@ @)) -(primitive: .public Set +(primitive .public Set (Tree :@: Block []) (def: .public (composite left right) diff --git a/stdlib/source/library/lux/documentation.lux b/stdlib/source/library/lux/documentation.lux index 9b1e70af6..abe8d3ff3 100644 --- a/stdlib/source/library/lux/documentation.lux +++ b/stdlib/source/library/lux/documentation.lux @@ -583,24 +583,29 @@ (def: .public default (syntax (_ [[name parameters] ..declaration]) - (let [[_ short] name] - (in (list (` (is (.List ..Definition) - (list [..#definition (~ (code.text short)) - ..#documentation ((~! ..minimal_definition_documentation) - ((~ (code.symbol name)) - (~+ (list#each code.local parameters))))])))))))) - -(def: .public documentation: + (macro.with_symbols [g!_] + (let [[_ short] name] + (in (list (` (.let [(~ g!_) (.is (.-> .Any (.List ..Definition)) + (.function ((~ g!_) (~ g!_)) + (.list [..#definition (~ (code.text short)) + ..#documentation ((~! ..minimal_definition_documentation) + ((~ (code.symbol name)) + (~+ (list#each code.local parameters))))])))] + ((~ g!_) []))))))))) + +(def: .public documentation (syntax (_ [[name parameters] ..declaration extra (<>.some <code>.any)]) - (let [[_ short] name] - (in (list (` (.def: .public (~ (code.local short)) - (.List ..Definition) - (.list [..#definition (~ (code.text short)) - ..#documentation ((~! ..definition_documentation) - ((~ (code.symbol name)) - (~+ (list#each code.local parameters))) - (~+ extra))])))))))) + (macro.with_symbols [g!_] + (let [[_ short] name] + (in (list (` (.let [(~ g!_) (.is (.-> .Any (.List ..Definition)) + (.function ((~ g!_) (~ g!_)) + (.list [..#definition (~ (code.text short)) + ..#documentation ((~! ..definition_documentation) + ((~ (code.symbol name)) + (~+ (list#each code.local parameters))) + (~+ extra))])))] + ((~ g!_) []))))))))) (def: definitions_documentation (-> (List Definition) (Markdown Block)) @@ -704,7 +709,7 @@ (..listing un_expected))) ))) -(def: .public documentation +(def: .public markdown (-> (List Module) Text) (|>> (list.sorted (function (_ left right) (text#< (the #module right) (the #module left)))) diff --git a/stdlib/source/library/lux/ffi.lux b/stdlib/source/library/lux/ffi.lux index 49cb0115b..65fb0ea9c 100644 --- a/stdlib/source/library/lux/ffi.lux +++ b/stdlib/source/library/lux/ffi.lux @@ -53,7 +53,7 @@ @.python "python function" @.lua "lua function" (these))] - (primitive: .public (Object brand) Any) + (primitive .public (Object brand) Any) (with_expansions [<un_common> (for @.js (these [Symbol] [Null] @@ -66,7 +66,7 @@ <un_common> <un_common>] (with_template [<name>] [(with_expansions [<brand> (template.symbol [<name> "'"])] - (primitive: <brand> + (primitive <brand> Any (type: .public <name> diff --git a/stdlib/source/library/lux/ffi.php.lux b/stdlib/source/library/lux/ffi.php.lux index fb56839d3..f354972a3 100644 --- a/stdlib/source/library/lux/ffi.php.lux +++ b/stdlib/source/library/lux/ffi.php.lux @@ -23,11 +23,11 @@ ["[0]" code] ["[0]" template]]]]) -(abstract: .public (Object brand) Any) +(primitive .public (Object brand) Any) (with_template [<name>] [(with_expansions [<brand> (template.symbol [<name> "'"])] - (abstract: .public <brand> Any) + (primitive .public <brand> Any) (type: .public <name> (..Object <brand>)))] diff --git a/stdlib/source/library/lux/ffi.scm.lux b/stdlib/source/library/lux/ffi.scm.lux index 257245540..79b59264d 100644 --- a/stdlib/source/library/lux/ffi.scm.lux +++ b/stdlib/source/library/lux/ffi.scm.lux @@ -23,11 +23,11 @@ ["[0]" code] ["[0]" template]]]]) -(abstract: .public (Object brand) Any) +(primitive .public (Object brand) Any) (with_template [<name>] [(with_expansions [<brand> (template.symbol [<name> "'"])] - (abstract: .public <brand> Any) + (primitive .public <brand> Any) (type: .public <name> (..Object <brand>)))] diff --git a/stdlib/source/library/lux/locale.lux b/stdlib/source/library/lux/locale.lux index 6b7d59c93..9587c8a8f 100644 --- a/stdlib/source/library/lux/locale.lux +++ b/stdlib/source/library/lux/locale.lux @@ -16,7 +16,7 @@ ["[0]" language (.only Language)] ["[0]" territory (.only Territory)]]) -(primitive: .public Locale +(primitive .public Locale Text (def: territory_separator "_") diff --git a/stdlib/source/library/lux/locale/language.lux b/stdlib/source/library/lux/locale/language.lux index e17fe5ff3..21930e92f 100644 --- a/stdlib/source/library/lux/locale/language.lux +++ b/stdlib/source/library/lux/locale/language.lux @@ -12,7 +12,7 @@ ["[0]" template]]]]) ... https://en.wikipedia.org/wiki/List_of_ISO_639-2_codes -(primitive: .public Language +(primitive .public Language (Record [#name Text #code Text]) diff --git a/stdlib/source/library/lux/locale/territory.lux b/stdlib/source/library/lux/locale/territory.lux index 26d65e515..b31531412 100644 --- a/stdlib/source/library/lux/locale/territory.lux +++ b/stdlib/source/library/lux/locale/territory.lux @@ -12,7 +12,7 @@ ["[0]" template]]]]) ... https://en.wikipedia.org/wiki/ISO_3166-1 -(primitive: .public Territory +(primitive .public Territory (Record [#name Text #short Text diff --git a/stdlib/source/library/lux/math/modular.lux b/stdlib/source/library/lux/math/modular.lux index d1e4860cd..c12f2111d 100644 --- a/stdlib/source/library/lux/math/modular.lux +++ b/stdlib/source/library/lux/math/modular.lux @@ -26,7 +26,7 @@ ["[0]" // ["[1]" modulus (.only Modulus)]]) -(primitive: .public (Mod m) +(primitive .public (Mod m) (Record [#modulus (Modulus m) #value Int]) diff --git a/stdlib/source/library/lux/math/modulus.lux b/stdlib/source/library/lux/math/modulus.lux index 43d341214..7071c834a 100644 --- a/stdlib/source/library/lux/math/modulus.lux +++ b/stdlib/source/library/lux/math/modulus.lux @@ -20,7 +20,7 @@ (exception: .public zero_cannot_be_a_modulus) -(primitive: .public (Modulus %) +(primitive .public (Modulus %) Int (def: .public (modulus value) diff --git a/stdlib/source/library/lux/target/common_lisp.lux b/stdlib/source/library/lux/target/common_lisp.lux index d058f5737..a95e1df67 100644 --- a/stdlib/source/library/lux/target/common_lisp.lux +++ b/stdlib/source/library/lux/target/common_lisp.lux @@ -20,7 +20,7 @@ (-> Text Text) (text.enclosed ["(" ")"])) -(primitive: .public (Code brand) +(primitive .public (Code brand) Text (def: .public manual @@ -33,7 +33,7 @@ (with_template [<type> <super>] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (`` (primitive: .public (<brand> brand) Any)) + (`` (primitive .public (<brand> brand) Any)) (`` (type: .public (<type> brand) (<super> (<brand> brand)))))] @@ -47,7 +47,7 @@ (with_template [<type> <super>] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (`` (primitive: .public <brand> Any)) + (`` (primitive .public <brand> Any)) (`` (type: .public <type> (<super> <brand>))))] [Label Code] diff --git a/stdlib/source/library/lux/target/js.lux b/stdlib/source/library/lux/target/js.lux index ddb2359a9..ae5ffe9d1 100644 --- a/stdlib/source/library/lux/target/js.lux +++ b/stdlib/source/library/lux/target/js.lux @@ -33,7 +33,7 @@ (|>> (format \n+) (text.replaced text.new_line (format text.new_line text.tab)))) -(primitive: .public (Code brand) +(primitive .public (Code brand) Text (def: .public code @@ -42,7 +42,7 @@ (with_template [<type> <super>+] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (primitive: (<brand> brand) Any) + (primitive (<brand> brand) Any) (`` (type: .public <type> (|> Any <brand> (~~ (template.spliced <super>+))))))] [Expression [Code]] @@ -53,7 +53,7 @@ (with_template [<type> <super>+] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (primitive: <brand> Any) + (primitive <brand> Any) (`` (type: .public <type> (|> <brand> (~~ (template.spliced <super>+))))))] [Var [Location' Computation' Expression' Code]] diff --git a/stdlib/source/library/lux/target/jvm/bytecode/address.lux b/stdlib/source/library/lux/target/jvm/bytecode/address.lux index 85952b623..ddb1331dc 100644 --- a/stdlib/source/library/lux/target/jvm/bytecode/address.lux +++ b/stdlib/source/library/lux/target/jvm/bytecode/address.lux @@ -23,7 +23,7 @@ ["[1][0]" unsigned (.only U2)] ["[1][0]" signed (.only S4)]]]]) -(primitive: .public Address +(primitive .public Address U2 (def: .public value diff --git a/stdlib/source/library/lux/target/jvm/bytecode/environment/limit/registry.lux b/stdlib/source/library/lux/target/jvm/bytecode/environment/limit/registry.lux index 21643a9c1..6e3642501 100644 --- a/stdlib/source/library/lux/target/jvm/bytecode/environment/limit/registry.lux +++ b/stdlib/source/library/lux/target/jvm/bytecode/environment/limit/registry.lux @@ -28,7 +28,7 @@ (def: normal 1) (def: wide 2) -(primitive: .public Registry +(primitive .public Registry U2 (def: .public registry diff --git a/stdlib/source/library/lux/target/jvm/bytecode/environment/limit/stack.lux b/stdlib/source/library/lux/target/jvm/bytecode/environment/limit/stack.lux index 891a6bc4f..a3cec4224 100644 --- a/stdlib/source/library/lux/target/jvm/bytecode/environment/limit/stack.lux +++ b/stdlib/source/library/lux/target/jvm/bytecode/environment/limit/stack.lux @@ -17,7 +17,7 @@ [encoding ["[1][0]" unsigned (.only U2)]]]) -(primitive: .public Stack +(primitive .public Stack U2 (with_template [<frames> <name>] diff --git a/stdlib/source/library/lux/target/jvm/bytecode/instruction.lux b/stdlib/source/library/lux/target/jvm/bytecode/instruction.lux index 498140007..9345f2ec2 100644 --- a/stdlib/source/library/lux/target/jvm/bytecode/instruction.lux +++ b/stdlib/source/library/lux/target/jvm/bytecode/instruction.lux @@ -221,7 +221,7 @@ [(n.+ (///unsigned.value ..size/211) size) (|>> mutation ((trinary/211' opcode input0 input1 input2)))])]) -(primitive: .public Primitive_Array_Type +(primitive .public Primitive_Array_Type U1 (def: code diff --git a/stdlib/source/library/lux/target/jvm/constant.lux b/stdlib/source/library/lux/target/jvm/constant.lux index d02197a09..8539fbf13 100644 --- a/stdlib/source/library/lux/target/jvm/constant.lux +++ b/stdlib/source/library/lux/target/jvm/constant.lux @@ -40,7 +40,7 @@ (Writer UTF8) binaryF.utf8_16) -(primitive: .public Class +(primitive .public Class (Index UTF8) (def: .public index @@ -82,7 +82,7 @@ "[1]::[0]" ("static" doubleToRawLongBits [double] long)) -(primitive: .public (Value kind) +(primitive .public (Value kind) kind (def: .public value diff --git a/stdlib/source/library/lux/target/jvm/constant/tag.lux b/stdlib/source/library/lux/target/jvm/constant/tag.lux index 88ec6eff2..2ac10790f 100644 --- a/stdlib/source/library/lux/target/jvm/constant/tag.lux +++ b/stdlib/source/library/lux/target/jvm/constant/tag.lux @@ -14,7 +14,7 @@ [encoding ["[1][0]" unsigned (.only U1) (.open: "u1//[0]" equivalence)]]]) -(primitive: .public Tag +(primitive .public Tag U1 (def: .public equivalence diff --git a/stdlib/source/library/lux/target/jvm/encoding/name.lux b/stdlib/source/library/lux/target/jvm/encoding/name.lux index 2dd465d20..2a322bace 100644 --- a/stdlib/source/library/lux/target/jvm/encoding/name.lux +++ b/stdlib/source/library/lux/target/jvm/encoding/name.lux @@ -13,7 +13,7 @@ (type: .public External Text) -(primitive: .public Internal +(primitive .public Internal Text (def: .public internal diff --git a/stdlib/source/library/lux/target/jvm/encoding/signed.lux b/stdlib/source/library/lux/target/jvm/encoding/signed.lux index c402c2300..822e420b2 100644 --- a/stdlib/source/library/lux/target/jvm/encoding/signed.lux +++ b/stdlib/source/library/lux/target/jvm/encoding/signed.lux @@ -22,7 +22,7 @@ [type [primitive (.except)]]]]) -(primitive: .public (Signed brand) +(primitive .public (Signed brand) Int (def: .public value @@ -50,7 +50,7 @@ (with_template [<bytes> <name> <size> <constructor> <maximum> <minimum> <+> <->] [(with_expansions [<raw> (template.symbol [<name> "'"])] - (primitive: <raw> Any) + (primitive <raw> Any) (type: .public <name> (Signed <raw>))) (def: .public <size> <bytes>) diff --git a/stdlib/source/library/lux/target/jvm/encoding/unsigned.lux b/stdlib/source/library/lux/target/jvm/encoding/unsigned.lux index 1c4d260dc..bdda3b8a5 100644 --- a/stdlib/source/library/lux/target/jvm/encoding/unsigned.lux +++ b/stdlib/source/library/lux/target/jvm/encoding/unsigned.lux @@ -21,7 +21,7 @@ [type [primitive (.except)]]]]) -(primitive: .public (Unsigned brand) +(primitive .public (Unsigned brand) Nat (def: .public value @@ -62,7 +62,7 @@ (with_template [<bytes> <name> <size> <constructor> <maximum> <+> <-> <max>] [(with_expansions [<raw> (template.symbol [<name> "'"])] - (primitive: .public <raw> Any) + (primitive .public <raw> Any) (type: .public <name> (Unsigned <raw>))) (def: .public <size> <bytes>) diff --git a/stdlib/source/library/lux/target/jvm/index.lux b/stdlib/source/library/lux/target/jvm/index.lux index 5fa1e0bb9..e3421fd14 100644 --- a/stdlib/source/library/lux/target/jvm/index.lux +++ b/stdlib/source/library/lux/target/jvm/index.lux @@ -15,7 +15,7 @@ (def: .public length //unsigned.bytes/2) -(primitive: .public (Index kind) +(primitive .public (Index kind) U2 (def: .public index diff --git a/stdlib/source/library/lux/target/jvm/modifier.lux b/stdlib/source/library/lux/target/jvm/modifier.lux index b76886f54..04db97f3f 100644 --- a/stdlib/source/library/lux/target/jvm/modifier.lux +++ b/stdlib/source/library/lux/target/jvm/modifier.lux @@ -23,7 +23,7 @@ [encoding ["[1][0]" unsigned]]]) -(primitive: .public (Modifier of) +(primitive .public (Modifier of) //unsigned.U2 (def: .public code diff --git a/stdlib/source/library/lux/target/jvm/modifier/inner.lux b/stdlib/source/library/lux/target/jvm/modifier/inner.lux index ee47de449..693946b75 100644 --- a/stdlib/source/library/lux/target/jvm/modifier/inner.lux +++ b/stdlib/source/library/lux/target/jvm/modifier/inner.lux @@ -2,10 +2,10 @@ [library [lux (.except static) [type - abstract]]] + [primitive (.except)]]]] [// (.only modifiers)]) -(abstract: .public Inner Any) +(primitive .public Inner Any) (modifiers Inner diff --git a/stdlib/source/library/lux/target/jvm/type.lux b/stdlib/source/library/lux/target/jvm/type.lux index 1f7362ee6..18c21263c 100644 --- a/stdlib/source/library/lux/target/jvm/type.lux +++ b/stdlib/source/library/lux/target/jvm/type.lux @@ -25,7 +25,7 @@ ["[1][0]" descriptor (.only Descriptor)] ["[1][0]" reflection (.only Reflection)]]) -(primitive: .public (Type category) +(primitive .public (Type category) [(Signature category) (Descriptor category) (Reflection category)] diff --git a/stdlib/source/library/lux/target/jvm/type/category.lux b/stdlib/source/library/lux/target/jvm/type/category.lux index 03e389d2a..c9115e3b4 100644 --- a/stdlib/source/library/lux/target/jvm/type/category.lux +++ b/stdlib/source/library/lux/target/jvm/type/category.lux @@ -6,24 +6,24 @@ [type [primitive (.except)]]]]) -(primitive: Void' Any) -(primitive: .public (Value' kind) Any) -(primitive: .public (Return' kind) Any) -(primitive: .public Method Any) +(primitive Void' Any) +(primitive .public (Value' kind) Any) +(primitive .public (Return' kind) Any) +(primitive .public Method Any) (type: .public Return (<| Return' Any)) (type: .public Value (<| Return' Value' Any)) (type: .public Void (<| Return' Void')) -(primitive: (Object' brand) Any) +(primitive (Object' brand) Any) (type: .public Object (<| Return' Value' Object' Any)) -(primitive: (Parameter' brand) Any) +(primitive (Parameter' brand) Any) (type: .public Parameter (<| Return' Value' Object' Parameter' Any)) (with_template [<parents> <child>] [(with_expansions [<raw> (template.symbol [<child> "'"])] - (primitive: <raw> Any) + (primitive <raw> Any) (type: .public <child> (`` (<| Return' Value' (~~ (template.spliced <parents>)) <raw>))))] @@ -33,5 +33,5 @@ [[Object' Parameter'] Array] ) -(primitive: .public Declaration Any) -(primitive: .public Inheritance Any) +(primitive .public Declaration Any) +(primitive .public Inheritance Any) diff --git a/stdlib/source/library/lux/target/jvm/type/descriptor.lux b/stdlib/source/library/lux/target/jvm/type/descriptor.lux index b5948d6f4..99b3987d5 100644 --- a/stdlib/source/library/lux/target/jvm/type/descriptor.lux +++ b/stdlib/source/library/lux/target/jvm/type/descriptor.lux @@ -21,7 +21,7 @@ [encoding ["[1][0]" name (.only Internal External)]]]]) -(primitive: .public (Descriptor category) +(primitive .public (Descriptor category) Text (def: .public descriptor diff --git a/stdlib/source/library/lux/target/jvm/type/lux.lux b/stdlib/source/library/lux/target/jvm/type/lux.lux index a9917f398..ea7951cee 100644 --- a/stdlib/source/library/lux/target/jvm/type/lux.lux +++ b/stdlib/source/library/lux/target/jvm/type/lux.lux @@ -30,7 +30,7 @@ ["[1][0]" name]]]]) (with_template [<name>] - [(primitive: .public (<name> class) Any)] + [(primitive .public (<name> class) Any)] [Lower] [Upper] ) diff --git a/stdlib/source/library/lux/target/jvm/type/reflection.lux b/stdlib/source/library/lux/target/jvm/type/reflection.lux index 33beded66..7794fedc3 100644 --- a/stdlib/source/library/lux/target/jvm/type/reflection.lux +++ b/stdlib/source/library/lux/target/jvm/type/reflection.lux @@ -15,7 +15,7 @@ [encoding ["[1][0]" name (.only External)]]]]) -(primitive: .public (Reflection category) +(primitive .public (Reflection category) Text (def: .public reflection diff --git a/stdlib/source/library/lux/target/jvm/type/signature.lux b/stdlib/source/library/lux/target/jvm/type/signature.lux index 04be4f980..610706176 100644 --- a/stdlib/source/library/lux/target/jvm/type/signature.lux +++ b/stdlib/source/library/lux/target/jvm/type/signature.lux @@ -20,7 +20,7 @@ [encoding ["[1][0]" name (.only External)]]]]) -(primitive: .public (Signature category) +(primitive .public (Signature category) Text (def: .public signature diff --git a/stdlib/source/library/lux/target/lua.lux b/stdlib/source/library/lux/target/lua.lux index ded81917a..67986980d 100644 --- a/stdlib/source/library/lux/target/lua.lux +++ b/stdlib/source/library/lux/target/lua.lux @@ -40,7 +40,7 @@ (def: input_separator ", ") -(primitive: .public (Code brand) +(primitive .public (Code brand) Text (def: .public equivalence @@ -65,7 +65,7 @@ (with_template [<type> <super>+] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (primitive: (<brand> brand) Any) + (primitive (<brand> brand) Any) (`` (type: .public <type> (|> Any <brand> (~~ (template.spliced <super>+))))))] [Expression [Code]] @@ -76,7 +76,7 @@ (with_template [<type> <super>+] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (primitive: <brand> Any) + (primitive <brand> Any) (`` (type: .public <type> (|> <brand> (~~ (template.spliced <super>+))))))] [Literal [Computation' Expression' Code]] diff --git a/stdlib/source/library/lux/target/php.lux b/stdlib/source/library/lux/target/php.lux index ddfdd0478..892b98a25 100644 --- a/stdlib/source/library/lux/target/php.lux +++ b/stdlib/source/library/lux/target/php.lux @@ -48,7 +48,7 @@ (-> Text Text) (text.enclosed ["(" ")"])) -(primitive: .public (Code brand) +(primitive .public (Code brand) Text (def: .public equivalence @@ -73,7 +73,7 @@ (with_template [<type> <super>+] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (primitive: (<brand> brand) Any) + (primitive (<brand> brand) Any) (`` (type: .public <type> (|> Any <brand> (~~ (template.spliced <super>+))))))] [Expression [Code]] @@ -84,7 +84,7 @@ (with_template [<type> <super>+] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (primitive: .public <brand> Any) + (primitive .public <brand> Any) (`` (type: .public <type> (|> <brand> (~~ (template.spliced <super>+))))))] [Literal [Computation' Expression' Code]] diff --git a/stdlib/source/library/lux/target/python.lux b/stdlib/source/library/lux/target/python.lux index 8d245f684..4e85ea258 100644 --- a/stdlib/source/library/lux/target/python.lux +++ b/stdlib/source/library/lux/target/python.lux @@ -57,7 +57,7 @@ (|>> (format \n+) (text.replaced text.new_line nested_new_line))))) -(primitive: .public (Code brand) +(primitive .public (Code brand) Text (def: .public equivalence @@ -82,7 +82,7 @@ (with_template [<type> <super>] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (`` (primitive: (<brand> brand) Any)) + (`` (primitive (<brand> brand) Any)) (`` (type: .public (<type> brand) (<super> (<brand> brand)))))] @@ -95,7 +95,7 @@ (with_template [<type> <super>] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (`` (primitive: <brand> Any)) + (`` (primitive <brand> Any)) (`` (type: .public <type> (<super> <brand>))))] [Literal Computation] @@ -104,7 +104,7 @@ ) (with_template [<var> <brand>] - [(primitive: .public <brand> Any) + [(primitive .public <brand> Any) (type: .public <var> (Var <brand>))] diff --git a/stdlib/source/library/lux/target/r.lux b/stdlib/source/library/lux/target/r.lux index a5658a87c..4956df9c0 100644 --- a/stdlib/source/library/lux/target/r.lux +++ b/stdlib/source/library/lux/target/r.lux @@ -22,12 +22,12 @@ [type [primitive (.except)]]]]) -(primitive: .public (Code kind) +(primitive .public (Code kind) Text (with_template [<type> <super>+] [(with_expansions [<kind> (template.symbol [<type> "'"])] - (primitive: .public (<kind> kind) Any) + (primitive .public (<kind> kind) Any) (`` (type: .public <type> (|> Any <kind> (~~ (template.spliced <super>+))))))] [Expression [Code]] @@ -35,14 +35,14 @@ (with_template [<type> <super>+] [(with_expansions [<kind> (template.symbol [<type> "'"])] - (primitive: .public (<kind> kind) Any) + (primitive .public (<kind> kind) Any) (`` (type: .public (<type> <brand>) (|> <brand> <kind> (~~ (template.spliced <super>+))))))] [Var [Expression' Code]] ) (with_template [<var> <kind>] - [(primitive: .public <kind> Any) + [(primitive .public <kind> Any) (type: .public <var> (Var <kind>))] [SVar Single] diff --git a/stdlib/source/library/lux/target/ruby.lux b/stdlib/source/library/lux/target/ruby.lux index 44e0018f9..ae928f407 100644 --- a/stdlib/source/library/lux/target/ruby.lux +++ b/stdlib/source/library/lux/target/ruby.lux @@ -40,7 +40,7 @@ (|>> (format \n+) (text.replaced text.new_line nested_new_line)))) -(primitive: .public (Code brand) +(primitive .public (Code brand) Text (def: .public equivalence @@ -59,7 +59,7 @@ (with_template [<type> <super>+] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (primitive: (<brand> brand) Any) + (primitive (<brand> brand) Any) (`` (type: .public <type> (|> Any <brand> (~~ (template.spliced <super>+))))))] [Expression [Code]] @@ -72,7 +72,7 @@ (with_template [<type> <super>+] [(with_expansions [<brand> (template.symbol [<type> "'"])] - (primitive: <brand> Any) + (primitive <brand> Any) (`` (type: .public <type> (|> <brand> (~~ (template.spliced <super>+))))))] [Literal [Computation' Expression' Code]] diff --git a/stdlib/source/library/lux/target/scheme.lux b/stdlib/source/library/lux/target/scheme.lux index ff7647574..c0632b5be 100644 --- a/stdlib/source/library/lux/target/scheme.lux +++ b/stdlib/source/library/lux/target/scheme.lux @@ -31,7 +31,7 @@ (.let [nested_new_line (format text.new_line text.tab)] (text.replaced text.new_line nested_new_line))) -(primitive: .public (Code k) +(primitive .public (Code k) Text (def: .public equivalence @@ -47,14 +47,14 @@ (def: hash (|>> representation (at text.hash hash))))) (with_template [<type> <brand> <super>+] - [(primitive: .public (<brand> brand) Any) + [(primitive .public (<brand> brand) Any) (`` (type: .public <type> (|> Any <brand> (~~ (template.spliced <super>+)))))] [Expression Expression' [Code]] ) (with_template [<type> <brand> <super>+] - [(primitive: .public <brand> Any) + [(primitive .public <brand> Any) (`` (type: .public <type> (|> <brand> (~~ (template.spliced <super>+)))))] [Var Var' [Expression' Code]] diff --git a/stdlib/source/library/lux/time.lux b/stdlib/source/library/lux/time.lux index 2416d3867..b977ceba1 100644 --- a/stdlib/source/library/lux/time.lux +++ b/stdlib/source/library/lux/time.lux @@ -76,7 +76,7 @@ [..seconds second_parser invalid_second ..section_parser] ) -(primitive: .public Time +(primitive .public Time Nat (def: .public midnight diff --git a/stdlib/source/library/lux/time/date.lux b/stdlib/source/library/lux/time/date.lux index 96f855fee..f01124fac 100644 --- a/stdlib/source/library/lux/time/date.lux +++ b/stdlib/source/library/lux/time/date.lux @@ -69,7 +69,7 @@ (def: separator "-") -(primitive: .public Date +(primitive .public Date (Record [#year Year #month Month diff --git a/stdlib/source/library/lux/time/duration.lux b/stdlib/source/library/lux/time/duration.lux index e608a8075..1b37584bf 100644 --- a/stdlib/source/library/lux/time/duration.lux +++ b/stdlib/source/library/lux/time/duration.lux @@ -23,7 +23,7 @@ ["[0]" // ["[1][0]" year]]) -(primitive: .public Duration +(primitive .public Duration Int (def: .public of_millis diff --git a/stdlib/source/library/lux/time/instant.lux b/stdlib/source/library/lux/time/instant.lux index 5298fdb17..daa4b8c2e 100644 --- a/stdlib/source/library/lux/time/instant.lux +++ b/stdlib/source/library/lux/time/instant.lux @@ -30,7 +30,7 @@ ["[0]" day (.only Day)] ["[0]" date (.only Date)]]) -(primitive: .public Instant +(primitive .public Instant Int (def: .public of_millis diff --git a/stdlib/source/library/lux/time/year.lux b/stdlib/source/library/lux/time/year.lux index 78093d222..244c8417f 100644 --- a/stdlib/source/library/lux/time/year.lux +++ b/stdlib/source/library/lux/time/year.lux @@ -35,7 +35,7 @@ (exception: .public there_is_no_year_0) ... https://en.wikipedia.org/wiki/Gregorian_calendar -(primitive: .public Year +(primitive .public Year Int (def: .public (year value) diff --git a/stdlib/source/library/lux/tool/compiler/meta/archive.lux b/stdlib/source/library/lux/tool/compiler/meta/archive.lux index 92c263466..bdb87cb95 100644 --- a/stdlib/source/library/lux/tool/compiler/meta/archive.lux +++ b/stdlib/source/library/lux/tool/compiler/meta/archive.lux @@ -71,7 +71,7 @@ #output Output #registry Registry])) -(primitive: .public Archive +(primitive .public Archive (Record [#next module.ID #resolver (Dictionary descriptor.Module [module.ID (Maybe (Entry Any))])]) diff --git a/stdlib/source/library/lux/tool/compiler/meta/archive/key.lux b/stdlib/source/library/lux/tool/compiler/meta/archive/key.lux index 62438a178..445e44c72 100644 --- a/stdlib/source/library/lux/tool/compiler/meta/archive/key.lux +++ b/stdlib/source/library/lux/tool/compiler/meta/archive/key.lux @@ -6,7 +6,7 @@ [// [signature (.only Signature)]]) -(primitive: .public (Key k) +(primitive .public (Key k) Signature (def: .public signature diff --git a/stdlib/source/library/lux/tool/compiler/meta/archive/module/document.lux b/stdlib/source/library/lux/tool/compiler/meta/archive/module/document.lux index ef3073cca..753950787 100644 --- a/stdlib/source/library/lux/tool/compiler/meta/archive/module/document.lux +++ b/stdlib/source/library/lux/tool/compiler/meta/archive/module/document.lux @@ -25,7 +25,7 @@ "Expected" (signature.description expected) "Actual" (signature.description actual))) -(primitive: .public (Document d) +(primitive .public (Document d) (Record [#signature Signature #content d]) diff --git a/stdlib/source/library/lux/tool/compiler/meta/archive/registry.lux b/stdlib/source/library/lux/tool/compiler/meta/archive/registry.lux index 0f15e8ca7..09cfc1190 100644 --- a/stdlib/source/library/lux/tool/compiler/meta/archive/registry.lux +++ b/stdlib/source/library/lux/tool/compiler/meta/archive/registry.lux @@ -29,7 +29,7 @@ ["[1]" artifact (.only Artifact ID) ["[2][0]" category (.only Category)]]]) -(primitive: .public Registry +(primitive .public Registry (Record [#artifacts (Sequence [Artifact (Set unit.ID)]) #resolver (Dictionary Text [ID (Maybe //category.Definition)])]) diff --git a/stdlib/source/library/lux/type/dynamic.lux b/stdlib/source/library/lux/type/dynamic.lux index 0c10c31bf..3797e528c 100644 --- a/stdlib/source/library/lux/type/dynamic.lux +++ b/stdlib/source/library/lux/type/dynamic.lux @@ -13,7 +13,7 @@ [macro (.only with_symbols) ["[0]" syntax (.only syntax)]] ["[0]" type (.only) - ["[0]" primitive (.only primitive:)]]]]) + ["[0]" primitive (.only primitive)]]]]) (exception: .public (wrong_type [expected Type actual Type]) @@ -21,7 +21,7 @@ "Expected" (%.type expected) "Actual" (%.type actual))) -(primitive: .public Dynamic +(primitive .public Dynamic [Type Any] (def: abstraction diff --git a/stdlib/source/library/lux/type/primitive.lux b/stdlib/source/library/lux/type/primitive.lux index b6dd7ff81..53202405e 100644 --- a/stdlib/source/library/lux/type/primitive.lux +++ b/stdlib/source/library/lux/type/primitive.lux @@ -225,7 +225,7 @@ ... TODO: Make sure the generated code always gets optimized away. ... (This applies to uses of "abstraction" and "representation") -(def: .public primitive: +(def: .public primitive (syntax (_ [[export_policy [name type_vars] representation_type primitives] ..abstract]) (do meta.monad diff --git a/stdlib/source/library/lux/type/quotient.lux b/stdlib/source/library/lux/type/quotient.lux index 9ae7ac08e..59f518ad8 100644 --- a/stdlib/source/library/lux/type/quotient.lux +++ b/stdlib/source/library/lux/type/quotient.lux @@ -11,7 +11,7 @@ ["[0]" type [primitive (.except)]]]]) -(primitive: .public (Class t c %) +(primitive .public (Class t c %) (-> t c) (def: .public class @@ -20,7 +20,7 @@ (-> (-> t c) (Class t c %)))) (|>> abstraction)) - (primitive: .public (Quotient t c %) + (primitive .public (Quotient t c %) (Record [#value t #label c]) diff --git a/stdlib/source/library/lux/type/refinement.lux b/stdlib/source/library/lux/type/refinement.lux index 6eefbe2fb..102ba9c5a 100644 --- a/stdlib/source/library/lux/type/refinement.lux +++ b/stdlib/source/library/lux/type/refinement.lux @@ -11,7 +11,7 @@ ["[0]" type (.only) [primitive (.except)]]]]) -(primitive: .public (Refined t %) +(primitive .public (Refined t %) (Record [#value t #predicate (Predicate t)]) diff --git a/stdlib/source/library/lux/type/resource.lux b/stdlib/source/library/lux/type/resource.lux index c9f7b13d7..0827dde1e 100644 --- a/stdlib/source/library/lux/type/resource.lux +++ b/stdlib/source/library/lux/type/resource.lux @@ -66,10 +66,10 @@ [output procedure] (in [keys output])))) -(primitive: .public Ordered Any) -(primitive: .public Commutative Any) +(primitive .public Ordered Any) +(primitive .public Commutative Any) -(primitive: .public (Key mode key) +(primitive .public (Key mode key) Any (with_template [<name> <mode>] @@ -81,7 +81,7 @@ [commutative_key Commutative] )) -(primitive: .public (Res key value) +(primitive .public (Res key value) value (with_template [<name> <mode> <key>] diff --git a/stdlib/source/library/lux/type/unit.lux b/stdlib/source/library/lux/type/unit.lux index 1d2cc20ca..631cc79a5 100644 --- a/stdlib/source/library/lux/type/unit.lux +++ b/stdlib/source/library/lux/type/unit.lux @@ -16,7 +16,7 @@ ["[0]" // (.only) [primitive (.except)]]) -(primitive: .public (Qty scale unit) +(primitive .public (Qty scale unit) Int (def: .public quantity diff --git a/stdlib/source/library/lux/world/db/sql.lux b/stdlib/source/library/lux/world/db/sql.lux index db9042b05..5c9fedc94 100644 --- a/stdlib/source/library/lux/world/db/sql.lux +++ b/stdlib/source/library/lux/world/db/sql.lux @@ -21,7 +21,7 @@ ... Kind (with_template [<declaration>] - [(primitive: .public <declaration> Any)] + [(primitive .public <declaration> Any)] [Literal'] [Column'] @@ -62,7 +62,7 @@ (def: .public no_alias Alias "") -(primitive: .public (SQL kind) +(primitive .public (SQL kind) Text ... SQL diff --git a/stdlib/source/library/lux/world/file/watch.lux b/stdlib/source/library/lux/world/file/watch.lux index 84f9cae1d..dc890fa54 100644 --- a/stdlib/source/library/lux/world/file/watch.lux +++ b/stdlib/source/library/lux/world/file/watch.lux @@ -29,10 +29,10 @@ [time ["[0]" instant (.only Instant) (.open: "[1]#[0]" equivalence)]] [type - [primitive (.only primitive: representation abstraction)]]]] + [primitive (.only primitive representation abstraction)]]]] ["[0]" //]) -(primitive: .public Concern +(primitive .public Concern (Record [#creation Bit #modification Bit diff --git a/stdlib/source/library/lux/world/net/http/mime.lux b/stdlib/source/library/lux/world/net/http/mime.lux index a1479c4c3..36a5bae3d 100644 --- a/stdlib/source/library/lux/world/net/http/mime.lux +++ b/stdlib/source/library/lux/world/net/http/mime.lux @@ -8,7 +8,7 @@ [type [primitive (.except)]]]]) -(primitive: .public MIME +(primitive .public MIME Text (def: .public mime diff --git a/stdlib/source/library/lux/world/program.lux b/stdlib/source/library/lux/world/program.lux index 7fcf31922..b0df93d8b 100644 --- a/stdlib/source/library/lux/world/program.lux +++ b/stdlib/source/library/lux/world/program.lux @@ -273,8 +273,8 @@ ... @.scheme ... (these (ffi.import (exit [Int] "io" Nothing)) ... ... https://srfi.schemers.org/srfi-98/srfi-98.html - ... (abstract: Pair Any) - ... (abstract: PList Any) + ... (primitive Pair Any) + ... (primitive PList Any) ... (ffi.import (get-environment-variables [] "io" PList)) ... (ffi.import (car [Pair] Text)) ... (ffi.import (cdr [Pair] Text)) |