From 8252bdb938a0284dd12e7365b4eb84b5357bacac Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Wed, 14 Jul 2021 14:44:18 -0400 Subject: Constant inlining. --- stdlib/source/library/lux.lux | 364 +++++++++++++++++++++--------------------- 1 file changed, 182 insertions(+), 182 deletions(-) (limited to 'stdlib') diff --git a/stdlib/source/library/lux.lux b/stdlib/source/library/lux.lux index 3a7fa442b..9b01303ea 100644 --- a/stdlib/source/library/lux.lux +++ b/stdlib/source/library/lux.lux @@ -27,10 +27,10 @@ ## (Ex [a] a)) ("lux def" Any ("lux type check type" - (9 #1 [..prelude_module "Any"] + (9 #1 ["library/lux" "Any"] (8 #0 (0 #0) (4 #0 1)))) [dummy_location - (9 #1 (0 #1 [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (0 #1 [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 ("lux text concat" ("lux text concat" "The type of things whose type is irrelevant." __paragraph) "It can be used to write functions or data-structures that can take, or return, anything."))]] @@ -41,10 +41,10 @@ ## (All [a] a)) ("lux def" Nothing ("lux type check type" - (9 #1 [..prelude_module "Nothing"] + (9 #1 ["library/lux" "Nothing"] (7 #0 (0 #0) (4 #0 1)))) [dummy_location - (9 #1 (0 #1 [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (0 #1 [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 ("lux text concat" ("lux text concat" "The type of things whose type is undefined." __paragraph) "Useful for expressions that cause errors or other 'extraordinary' conditions."))]] @@ -55,7 +55,7 @@ ## #Nil ## (#Cons a (List a))) ("lux def type tagged" List - (9 #1 [..prelude_module "List"] + (9 #1 ["library/lux" "List"] (7 #0 (0 #0) (1 #0 ## "lux.Nil" Any @@ -63,9 +63,9 @@ (2 #0 (4 #0 1) (9 #0 (4 #0 1) (4 #0 0)))))) [dummy_location - (9 #1 (0 #1 [[dummy_location (7 #0 [..prelude_module "type-args"])] + (9 #1 (0 #1 [[dummy_location (7 #0 ["library/lux" "type-args"])] [dummy_location (9 #0 (0 #1 [dummy_location (5 #0 "a")] (0 #0)))]] - (0 #1 [[dummy_location (7 #0 [..prelude_module "doc"])] + (0 #1 [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 "A potentially empty list of values.")]] (0 #0))))] ["Nil" "Cons"] @@ -73,31 +73,31 @@ ("lux def" Bit ("lux type check type" - (9 #1 [..prelude_module "Bit"] + (9 #1 ["library/lux" "Bit"] (0 #0 "#Bit" #Nil))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 "Your standard, run-of-the-mill boolean values (as bits).")]] #Nil))] #1) ("lux def" I64 ("lux type check type" - (9 #1 [..prelude_module "I64"] + (9 #1 ["library/lux" "I64"] (7 #0 (0 #0) (0 #0 "#I64" (#Cons (4 #0 1) #Nil))))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 "64-bit integers without any semantics.")]] #Nil))] #1) ("lux def" Nat ("lux type check type" - (9 #1 [..prelude_module "Nat"] + (9 #1 ["library/lux" "Nat"] (0 #0 "#I64" (#Cons (0 #0 "#Nat" #Nil) #Nil)))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 ("lux text concat" ("lux text concat" "Natural numbers (unsigned integers)." __paragraph) "They start at zero (0) and extend in the positive direction."))]] @@ -106,20 +106,20 @@ ("lux def" Int ("lux type check type" - (9 #1 [..prelude_module "Int"] + (9 #1 ["library/lux" "Int"] (0 #0 "#I64" (#Cons (0 #0 "#Int" #Nil) #Nil)))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 "Your standard, run-of-the-mill integer numbers.")]] #Nil))] #1) ("lux def" Rev ("lux type check type" - (9 #1 [..prelude_module "Rev"] + (9 #1 ["library/lux" "Rev"] (0 #0 "#I64" (#Cons (0 #0 "#Rev" #Nil) #Nil)))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 ("lux text concat" ("lux text concat" "Fractional numbers that live in the interval [0,1)." __paragraph) "Useful for probability, and other domains that work within that interval."))]] @@ -128,30 +128,30 @@ ("lux def" Frac ("lux type check type" - (9 #1 [..prelude_module "Frac"] + (9 #1 ["library/lux" "Frac"] (0 #0 "#Frac" #Nil))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 "Your standard, run-of-the-mill floating-point (fractional) numbers.")]] #Nil))] #1) ("lux def" Text ("lux type check type" - (9 #1 [..prelude_module "Text"] + (9 #1 ["library/lux" "Text"] (0 #0 "#Text" #Nil))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 "Your standard, run-of-the-mill string values.")]] #Nil))] #1) ("lux def" Name ("lux type check type" - (9 #1 [..prelude_module "Name"] + (9 #1 ["library/lux" "Name"] (2 #0 Text Text))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 "A name. It is used as part of Lux syntax to represent identifiers and tags.")]] #Nil))] #1) @@ -160,16 +160,16 @@ ## #None ## (#Some a)) ("lux def type tagged" Maybe - (9 #1 [..prelude_module "Maybe"] + (9 #1 ["library/lux" "Maybe"] (7 #0 #Nil (1 #0 ## "lux.None" Any ## "lux.Some" (4 #0 1)))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "type-args"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "type-args"])] [dummy_location (9 #0 (#Cons [dummy_location (5 #0 "a")] #Nil))]] - (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 "A potentially missing value.")]] #Nil)))] ["None" "Some"] @@ -189,7 +189,7 @@ ## (#Named Name Type) ## ) ("lux def type tagged" Type - (9 #1 [..prelude_module "Type"] + (9 #1 ["library/lux" "Type"] ({Type ({Type_List ({Type_Pair @@ -221,9 +221,9 @@ ("lux type check type" (9 #0 Type List)))} ("lux type check type" (9 #0 (4 #0 1) (4 #0 0))))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 "This type represents the data-structures that are used to specify types themselves.")]] - (#Cons [[dummy_location (7 #0 [..prelude_module "type-rec?"])] + (#Cons [[dummy_location (7 #0 ["library/lux" "type-rec?"])] [dummy_location (0 #0 #1)]] #Nil)))] ["Primitive" "Sum" "Product" "Function" "Parameter" "Var" "Ex" "UnivQ" "ExQ" "Apply" "Named"] @@ -234,10 +234,10 @@ ## #line Nat ## #column Nat}) ("lux def type tagged" Location - (#Named [..prelude_module "Location"] + (#Named ["library/lux" "Location"] (#Product Text (#Product Nat Nat))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 "Locations are for specifying the location of Code nodes in Lux files during compilation.")]] #Nil))] ["module" "line" "column"] @@ -247,15 +247,15 @@ ## {#meta m ## #datum v}) ("lux def type tagged" Ann - (#Named [..prelude_module "Ann"] + (#Named ["library/lux" "Ann"] (#UnivQ #Nil (#UnivQ #Nil (#Product (#Parameter 3) (#Parameter 1))))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "doc"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "doc"])] [dummy_location (5 #0 "The type of things that can be annotated with meta-data of arbitrary types.")]] - (#Cons [[dummy_location (7 #0 [..prelude_module "type-args"])] + (#Cons [[dummy_location (7 #0 ["library/lux" "type-args"])] [dummy_location (9 #0 (#Cons [dummy_location (5 #0 "m")] (#Cons [dummy_location (5 #0 "v")] #Nil)))]] #Nil)))] ["meta" "datum"] @@ -274,7 +274,7 @@ ## (#Tuple (List (w (Code' w)))) ## (#Record (List [(w (Code' w)) (w (Code' w))]))) ("lux def type tagged" Code' - (#Named [..prelude_module "Code'"] + (#Named ["library/lux" "Code'"] ({Code ({Code_List (#UnivQ #Nil @@ -307,7 +307,7 @@ (#Parameter 0)) (#Parameter 1))))) [dummy_location - (9 #1 (#Cons [[dummy_location (7 #0 [..prelude_module "type-args"])] + (9 #1 (#Cons [[dummy_location (7 #0 ["library/lux" "type-args"])] [dummy_location (9 #0 (#Cons [dummy_location (5 #0 "w")] #Nil))]] #Nil))] ["Bit" "Nat" "Int" "Rev" "Frac" "Text" "Identifier" "Tag" "Form" "Tuple" "Record"] @@ -316,12 +316,12 @@ ## (type: Code ## (Ann Location (Code' (Ann Location)))) ("lux def" Code - (#Named [..prelude_module "Code"] + (#Named ["library/lux" "Code"] ({w (#Apply (#Apply w Code') w)} ("lux type check type" (#Apply Location Ann)))) [dummy_location - (#Record (#Cons [[dummy_location (#Tag [..prelude_module "doc"])] + (#Record (#Cons [[dummy_location (#Tag ["library/lux" "doc"])] [dummy_location (#Text "The type of Code nodes for Lux syntax.")]] #Nil))] #1) @@ -418,9 +418,9 @@ ## [Bit Type Code Any]) ("lux def" Definition ("lux type check type" - (#Named [..prelude_module "Definition"] + (#Named ["library/lux" "Definition"] (#Product Bit (#Product Type (#Product Code Any))))) - (record$ (#Cons [(tag$ [..prelude_module "doc"]) + (record$ (#Cons [(tag$ ["library/lux" "doc"]) (text$ "Represents all the data associated with a definition: its type, its annotations, and its value.")] #Nil)) #1) @@ -429,7 +429,7 @@ ## Name) ("lux def" Alias ("lux type check type" - (#Named [..prelude_module "Alias"] + (#Named ["library/lux" "Alias"] Name)) (record$ #Nil) #1) @@ -438,10 +438,10 @@ ## (#Alias Alias) ## (#Definition Definition)) ("lux def type tagged" Global - (#Named [..prelude_module "Global"] + (#Named ["library/lux" "Global"] (#Sum Alias Definition)) - (record$ (#Cons [(tag$ [..prelude_module "doc"]) + (record$ (#Cons [(tag$ ["library/lux" "doc"]) (text$ "Represents all the data associated with a global constant.")] #Nil)) ["Alias" "Definition"] @@ -451,7 +451,7 @@ ## {#counter Nat ## #mappings (List [k v])}) ("lux def type tagged" Bindings - (#Named [..prelude_module "Bindings"] + (#Named ["library/lux" "Bindings"] (#UnivQ #Nil (#UnivQ #Nil (#Product ## "lux.counter" @@ -460,7 +460,7 @@ (#Apply (#Product (#Parameter 3) (#Parameter 1)) List))))) - (record$ (#Cons [(tag$ [..prelude_module "type-args"]) + (record$ (#Cons [(tag$ ["library/lux" "type-args"]) (tuple$ (#Cons (text$ "k") (#Cons (text$ "v") #Nil)))] #Nil)) ["counter" "mappings"] @@ -470,7 +470,7 @@ ## (#Local Nat) ## (#Captured Nat)) ("lux def type tagged" Ref - (#Named [..prelude_module "Ref"] + (#Named ["library/lux" "Ref"] (#Sum ## Local Nat ## Captured @@ -485,7 +485,7 @@ ## #locals (Bindings Text [Type Nat]) ## #captured (Bindings Text [Type Ref])}) ("lux def type tagged" Scope - (#Named [..prelude_module "Scope"] + (#Named ["library/lux" "Scope"] (#Product ## name (#Apply Text List) (#Product ## inner @@ -508,16 +508,16 @@ ## (#Left l) ## (#Right r)) ("lux def type tagged" Either - (#Named [..prelude_module "Either"] + (#Named ["library/lux" "Either"] (#UnivQ #Nil (#UnivQ #Nil (#Sum ## "lux.Left" (#Parameter 3) ## "lux.Right" (#Parameter 1))))) - (record$ (#Cons [(tag$ [..prelude_module "type-args"]) + (record$ (#Cons [(tag$ ["library/lux" "type-args"]) (tuple$ (#Cons (text$ "l") (#Cons (text$ "r") #Nil)))] - (#Cons [(tag$ [..prelude_module "doc"]) + (#Cons [(tag$ ["library/lux" "doc"]) (text$ "A choice between two values of different types.")] #Nil))) ["Left" "Right"] @@ -527,7 +527,7 @@ ## [Location Nat Text]) ("lux def" Source ("lux type check type" - (#Named [..prelude_module "Source"] + (#Named ["library/lux" "Source"] (#Product Location (#Product Nat Text)))) (record$ #Nil) #1) @@ -537,7 +537,7 @@ ## #Compiled ## #Cached) ("lux def type tagged" Module_State - (#Named [..prelude_module "Module_State"] + (#Named ["library/lux" "Module_State"] (#Sum ## #Active Any @@ -560,7 +560,7 @@ ## #module_annotations (Maybe Code) ## #module_state Module_State}) ("lux def type tagged" Module - (#Named [..prelude_module "Module"] + (#Named ["library/lux" "Module"] (#Product ## "lux.module_hash" Nat (#Product ## "lux.module_aliases" @@ -586,7 +586,7 @@ (#Apply Code Maybe) Module_State)) )))))) - (record$ (#Cons [(tag$ [..prelude_module "doc"]) + (record$ (#Cons [(tag$ ["library/lux" "doc"]) (text$ "All the information contained within a Lux module.")] #Nil)) ["module_hash" "module_aliases" "definitions" "imports" "tags" "types" "module_annotations" "module_state"] @@ -597,7 +597,7 @@ ## #var_counter Nat ## #var_bindings (List [Nat (Maybe Type)])}) ("lux def type tagged" Type_Context - (#Named [..prelude_module "Type_Context"] + (#Named ["library/lux" "Type_Context"] (#Product ## ex_counter Nat (#Product ## var_counter @@ -614,14 +614,14 @@ ## #Eval ## #Interpreter) ("lux def type tagged" Mode - (#Named [..prelude_module "Mode"] + (#Named ["library/lux" "Mode"] (#Sum ## Build Any (#Sum ## Eval Any ## Interpreter Any))) - (record$ (#Cons [(tag$ [..prelude_module "doc"]) + (record$ (#Cons [(tag$ ["library/lux" "doc"]) (text$ "A sign that shows the conditions under which the compiler is running.")] #Nil)) ["Build" "Eval" "Interpreter"] @@ -632,7 +632,7 @@ ## #version Text ## #mode Mode}) ("lux def type tagged" Info - (#Named [..prelude_module "Info"] + (#Named ["library/lux" "Info"] (#Product ## target Text @@ -641,7 +641,7 @@ Text ## mode Mode))) - (record$ (#Cons [(tag$ [..prelude_module "doc"]) + (record$ (#Cons [(tag$ ["library/lux" "doc"]) (text$ "Information about the current version and type of compiler that is running.")] #Nil)) ["target" "version" "mode"] @@ -661,7 +661,7 @@ ## #extensions Any ## #host Any}) ("lux def type tagged" Lux - (#Named [..prelude_module "Lux"] + (#Named ["library/lux" "Lux"] (#Product ## "lux.info" Info (#Product ## "lux.source" @@ -686,7 +686,7 @@ Any ## "lux.host" Any)))))))))))) - (record$ (#Cons [(tag$ [..prelude_module "doc"]) + (record$ (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "Represents the state of the Lux compiler during a run." __paragraph) ("lux text concat" @@ -700,16 +700,16 @@ ## (-> Lux (Either Text [Lux a]))) ("lux def" Meta ("lux type check type" - (#Named [..prelude_module "Meta"] + (#Named ["library/lux" "Meta"] (#UnivQ #Nil (#Function Lux (#Apply (#Product Lux (#Parameter 1)) (#Apply Text Either)))))) - (record$ (#Cons [(tag$ [..prelude_module "doc"]) + (record$ (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "Computations that can have access to the state of the compiler." __paragraph) "These computations may fail, or modify the state of the compiler."))] - (#Cons [(tag$ [..prelude_module "type-args"]) + (#Cons [(tag$ ["library/lux" "type-args"]) (tuple$ (#Cons (text$ "a") #Nil))] #Nil))) #1) @@ -718,7 +718,7 @@ ## (-> (List Code) (Meta (List Code)))) ("lux def" Macro' ("lux type check type" - (#Named [..prelude_module "Macro'"] + (#Named ["library/lux" "Macro'"] (#Function Code_List (#Apply Code_List Meta)))) (record$ #Nil) #1) @@ -727,9 +727,9 @@ ## (primitive "#Macro")) ("lux def" Macro ("lux type check type" - (#Named [..prelude_module "Macro"] + (#Named ["library/lux" "Macro"] (#Primitive "#Macro" #Nil))) - (record$ (#Cons [(tag$ [..prelude_module "doc"]) + (record$ (#Cons [(tag$ ["library/lux" "doc"]) (text$ "Functions that run at compile-time and allow you to transform and extend the language in powerful ways.")] #Nil)) #1) @@ -786,7 +786,7 @@ body _ - (_ann (#Form (#Cons (_ann (#Identifier [..prelude_module "function''"])) + (_ann (#Form (#Cons (_ann (#Identifier ["library/lux" "function''"])) (#Cons (_ann (#Tuple args')) (#Cons body #Nil)))))} args') @@ -800,7 +800,7 @@ body _ - (_ann (#Form (#Cons (_ann (#Identifier [..prelude_module "function''"])) + (_ann (#Form (#Cons (_ann (#Identifier ["library/lux" "function''"])) (#Cons (_ann (#Tuple args')) (#Cons body #Nil)))))} args') @@ -832,15 +832,15 @@ ("lux def" flag_meta ("lux type check" (#Function Text Code) ([_ tag] - (tuple$ (#Cons [(meta_code [..prelude_module "Tag"] (tuple$ (#Cons (text$ ..prelude_module) (#Cons (text$ tag) #Nil)))) - (#Cons [(meta_code [..prelude_module "Bit"] (bit$ #1)) + (tuple$ (#Cons [(meta_code ["library/lux" "Tag"] (tuple$ (#Cons (text$ "library/lux") (#Cons (text$ tag) #Nil)))) + (#Cons [(meta_code ["library/lux" "Bit"] (bit$ #1)) #Nil])])))) (record$ #Nil) #0) ("lux def" doc_meta ("lux type check" (#Function Text (#Product Code Code)) - (function'' [doc] [(tag$ [..prelude_module "doc"]) (text$ doc)])) + (function'' [doc] [(tag$ ["library/lux" "doc"]) (text$ doc)])) (record$ #Nil) #0) @@ -861,7 +861,7 @@ ("lux def" as_function ("lux type check" (#Function Code (#Function (#Apply Code List) (#Function Code Code))) (function'' [self inputs output] - (form$ (#Cons (identifier$ [..prelude_module "function''"]) + (form$ (#Cons (identifier$ ["library/lux" "function''"]) (#Cons self (#Cons (tuple$ inputs) (#Cons output #Nil))))))) @@ -884,7 +884,7 @@ (#Cons [[_ (#Form (#Cons [name args]))] (#Cons [meta (#Cons [type (#Cons [body #Nil])])])])]) (return (#Cons [(as_def name (as_checked type (as_function name args body)) - (form$ (#Cons (identifier$ [..prelude_module "record$"]) + (form$ (#Cons (identifier$ ["library/lux" "record$"]) (#Cons meta #Nil))) #1) @@ -892,7 +892,7 @@ (#Cons [[_ (#Tag ["" "export"])] (#Cons [name (#Cons [meta (#Cons [type (#Cons [body #Nil])])])])]) (return (#Cons [(as_def name (as_checked type body) - (form$ (#Cons (identifier$ [..prelude_module "record$"]) + (form$ (#Cons (identifier$ ["library/lux" "record$"]) (#Cons meta #Nil))) #1) @@ -901,7 +901,7 @@ (#Cons [[_ (#Form (#Cons [name args]))] (#Cons [meta (#Cons [type (#Cons [body #Nil])])])]) (return (#Cons [(as_def name (as_checked type (as_function name args body)) - (form$ (#Cons (identifier$ [..prelude_module "record$"]) + (form$ (#Cons (identifier$ ["library/lux" "record$"]) (#Cons meta #Nil))) #0) @@ -909,7 +909,7 @@ (#Cons [name (#Cons [meta (#Cons [type (#Cons [body #Nil])])])]) (return (#Cons [(as_def name (as_checked type body) - (form$ (#Cons (identifier$ [..prelude_module "record$"]) + (form$ (#Cons (identifier$ ["library/lux" "record$"]) (#Cons meta #Nil))) #0) @@ -926,23 +926,23 @@ (function'' [tokens] ({(#Cons [_ (#Form (#Cons name args))] (#Cons body #Nil)) (return (#Cons (as_def name (as_macro (as_function name args body)) - (form$ (#Cons (identifier$ [..prelude_module "record$"]) - (#Cons (tag$ [..prelude_module "Nil"]) + (form$ (#Cons (identifier$ ["library/lux" "record$"]) + (#Cons (tag$ ["library/lux" "Nil"]) #Nil))) #0) #Nil)) (#Cons [_ (#Tag ["" "export"])] (#Cons [_ (#Form (#Cons name args))] (#Cons body #Nil))) (return (#Cons (as_def name (as_macro (as_function name args body)) - (form$ (#Cons (identifier$ [..prelude_module "record$"]) - (#Cons (tag$ [..prelude_module "Nil"]) + (form$ (#Cons (identifier$ ["library/lux" "record$"]) + (#Cons (tag$ ["library/lux" "Nil"]) #Nil))) #1) #Nil)) (#Cons [_ (#Tag ["" "export"])] (#Cons [_ (#Form (#Cons name args))] (#Cons meta_data (#Cons body #Nil)))) (return (#Cons (as_def name (as_macro (as_function name args body)) - (form$ (#Cons (identifier$ [..prelude_module "record$"]) + (form$ (#Cons (identifier$ ["library/lux" "record$"]) (#Cons meta_data #Nil))) #1) @@ -955,7 +955,7 @@ #0) (macro:' #export (comment tokens) - (#Cons [(tag$ [..prelude_module "doc"]) + (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "## Throws away any code given to it." __paragraph) ("lux text concat" @@ -969,8 +969,8 @@ (return tokens) (#Cons x (#Cons y xs)) - (return (#Cons (form$ (#Cons (identifier$ [..prelude_module "$'"]) - (#Cons (form$ (#Cons (tag$ [..prelude_module "Apply"]) + (return (#Cons (form$ (#Cons (identifier$ ["library/lux" "$'"]) + (#Cons (form$ (#Cons (tag$ ["library/lux" "Apply"]) (#Cons y (#Cons x #Nil)))) xs))) #Nil)) @@ -1079,7 +1079,7 @@ pairs)) [_ (#Form (#Cons [_ (#Tag "library/lux" "Parameter")] (#Cons [_ (#Nat idx)] #Nil)))] - (form$ (#Cons (tag$ [..prelude_module "Parameter"]) (#Cons (nat$ ("lux i64 +" 2 idx)) #Nil))) + (form$ (#Cons (tag$ ["library/lux" "Parameter"]) (#Cons (nat$ ("lux i64 +" 2 idx)) #Nil))) [_ (#Form members)] (form$ (list\map update_parameters members)) @@ -1108,7 +1108,7 @@ (def:'' (make_parameter idx) #Nil (#Function Nat Code) - (form$ (#Cons (tag$ [..prelude_module "Parameter"]) (#Cons (nat$ idx) #Nil)))) + (form$ (#Cons (tag$ ["library/lux" "Parameter"]) (#Cons (nat$ idx) #Nil)))) (def:'' (list\fold f init xs) #Nil @@ -1133,7 +1133,7 @@ (list\fold (function'' [_ acc] ("lux i64 +" 1 acc)) 0 list)) (macro:' #export (All tokens) - (#Cons [(tag$ [..prelude_module "doc"]) + (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "## Universal quantification." __paragraph) ("lux text concat" @@ -1153,8 +1153,8 @@ (function'' [names] (let'' body' (list\fold ("lux type check" (#Function Text (#Function Code Code)) (function'' [name' body'] - (form$ (#Cons (tag$ [..prelude_module "UnivQ"]) - (#Cons (tag$ [..prelude_module "Nil"]) + (form$ (#Cons (tag$ ["library/lux" "UnivQ"]) + (#Cons (tag$ ["library/lux" "Nil"]) (#Cons (replace_syntax (#Cons [name' (make_parameter 1)] #Nil) (update_parameters body')) #Nil)))))) body @@ -1177,7 +1177,7 @@ tokens))) (macro:' #export (Ex tokens) - (#Cons [(tag$ [..prelude_module "doc"]) + (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "## Existential quantification." __paragraph) ("lux text concat" @@ -1197,8 +1197,8 @@ (function'' [names] (let'' body' (list\fold ("lux type check" (#Function Text (#Function Code Code)) (function'' [name' body'] - (form$ (#Cons (tag$ [..prelude_module "ExQ"]) - (#Cons (tag$ [..prelude_module "Nil"]) + (form$ (#Cons (tag$ ["library/lux" "ExQ"]) + (#Cons (tag$ ["library/lux" "Nil"]) (#Cons (replace_syntax (#Cons [name' (make_parameter 1)] #Nil) (update_parameters body')) #Nil)))))) body @@ -1229,7 +1229,7 @@ list)) (macro:' #export (-> tokens) - (#Cons [(tag$ [..prelude_module "doc"]) + (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "## Function types:" __paragraph) ("lux text concat" @@ -1238,7 +1238,7 @@ #Nil) ({(#Cons output inputs) (return (#Cons (list\fold ("lux type check" (#Function Code (#Function Code Code)) - (function'' [i o] (form$ (#Cons (tag$ [..prelude_module "Function"]) (#Cons i (#Cons o #Nil)))))) + (function'' [i o] (form$ (#Cons (tag$ ["library/lux" "Function"]) (#Cons i (#Cons o #Nil)))))) output inputs) #Nil)) @@ -1248,21 +1248,21 @@ (list\reverse tokens))) (macro:' #export (list xs) - (#Cons [(tag$ [..prelude_module "doc"]) + (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "## List-construction macro." __paragraph) "(list +1 +2 +3)"))] #Nil) (return (#Cons (list\fold (function'' [head tail] - (form$ (#Cons (tag$ [..prelude_module "Cons"]) + (form$ (#Cons (tag$ ["library/lux" "Cons"]) (#Cons (tuple$ (#Cons [head (#Cons [tail #Nil])])) #Nil)))) - (tag$ [..prelude_module "Nil"]) + (tag$ ["library/lux" "Nil"]) (list\reverse xs)) #Nil))) (macro:' #export (list& xs) - (#Cons [(tag$ [..prelude_module "doc"]) + (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "## List-construction macro, with the last element being a tail-list." __paragraph) ("lux text concat" @@ -1271,7 +1271,7 @@ #Nil) ({(#Cons last init) (return (list (list\fold (function'' [head tail] - (form$ (list (tag$ [..prelude_module "Cons"]) + (form$ (list (tag$ ["library/lux" "Cons"]) (tuple$ (list head tail))))) last init))) @@ -1281,7 +1281,7 @@ (list\reverse xs))) (macro:' #export (& tokens) - (#Cons [(tag$ [..prelude_module "doc"]) + (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "## Tuple types:" __paragraph) ("lux text concat" @@ -1291,16 +1291,16 @@ "(&)"))))] #Nil) ({#Nil - (return (list (identifier$ [..prelude_module "Any"]))) + (return (list (identifier$ ["library/lux" "Any"]))) (#Cons last prevs) - (return (list (list\fold (function'' [left right] (form$ (list (tag$ [..prelude_module "Product"]) left right))) + (return (list (list\fold (function'' [left right] (form$ (list (tag$ ["library/lux" "Product"]) left right))) last prevs)))} (list\reverse tokens))) (macro:' #export (| tokens) - (#Cons [(tag$ [..prelude_module "doc"]) + (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "## Variant types:" __paragraph) ("lux text concat" @@ -1310,10 +1310,10 @@ "(|)"))))] #Nil) ({#Nil - (return (list (identifier$ [..prelude_module "Nothing"]))) + (return (list (identifier$ ["library/lux" "Nothing"]))) (#Cons last prevs) - (return (list (list\fold (function'' [left right] (form$ (list (tag$ [..prelude_module "Sum"]) left right))) + (return (list (list\fold (function'' [left right] (form$ (list (tag$ ["library/lux" "Sum"]) left right))) last prevs)))} (list\reverse tokens))) @@ -1352,11 +1352,11 @@ name (form$ (list (text$ "lux type check") type - (form$ (list (identifier$ [..prelude_module "function'"]) + (form$ (list (identifier$ ["library/lux" "function'"]) name (tuple$ args) body)))) - (form$ (#Cons (identifier$ [..prelude_module "record$"]) + (form$ (#Cons (identifier$ ["library/lux" "record$"]) (#Cons meta #Nil))) (bit$ #1))))) @@ -1367,7 +1367,7 @@ (form$ (list (text$ "lux type check") type body)) - (form$ (#Cons (identifier$ [..prelude_module "record$"]) + (form$ (#Cons (identifier$ ["library/lux" "record$"]) (#Cons meta #Nil))) (bit$ #1))))) @@ -1378,11 +1378,11 @@ name (form$ (list (text$ "lux type check") type - (form$ (list (identifier$ [..prelude_module "function'"]) + (form$ (list (identifier$ ["library/lux" "function'"]) name (tuple$ args) body)))) - (form$ (#Cons (identifier$ [..prelude_module "record$"]) + (form$ (#Cons (identifier$ ["library/lux" "record$"]) (#Cons meta #Nil))) (bit$ #0))))) @@ -1391,7 +1391,7 @@ (return (list (form$ (list (text$ "lux def") name (form$ (list (text$ "lux type check") type body)) - (form$ (#Cons (identifier$ [..prelude_module "record$"]) + (form$ (#Cons (identifier$ ["library/lux" "record$"]) (#Cons meta #Nil))) (bit$ #0))))) @@ -1448,10 +1448,10 @@ #Nil (-> ($' List Code) Code) ({#Nil - (_ann (#Tag [..prelude_module "Nil"])) + (_ann (#Tag ["library/lux" "Nil"])) (#Cons [token tokens']) - (_ann (#Form (list (_ann (#Tag [..prelude_module "Cons"])) token (untemplate_list tokens'))))} + (_ann (#Form (list (_ann (#Tag ["library/lux" "Cons"])) token (untemplate_list tokens'))))} tokens)) (def:''' (list\compose xs ys) @@ -1482,7 +1482,7 @@ (func left right))) (macro:' #export (_$ tokens) - (#Cons [(tag$ [..prelude_module "doc"]) + (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "## Left-association for the application of binary functions over variadic arguments." ..\n) ("lux text concat" @@ -1504,7 +1504,7 @@ tokens)) (macro:' #export ($_ tokens) - (#Cons [(tag$ [..prelude_module "doc"]) + (#Cons [(tag$ ["library/lux" "doc"]) (text$ ("lux text concat" ("lux text concat" "## Right-association for the application of binary functions over variadic arguments." ..\n) ("lux text concat" @@ -1531,7 +1531,7 @@ ## (: (All [a b] (-> (-> a (m b)) (m a) (m b))) ## bind)) ("lux def type tagged" Monad - (#Named [..prelude_module "Monad"] + (#Named ["library/lux" "Monad"] (All [m] (& (All [a] (-> a ($' m a))) (All [a b] (-> (-> a ($' m b)) @@ -1579,7 +1579,7 @@ (function' [binding body'] (let' [[var value] binding] ({[_ (#Tag "" "let")] - (form$ (list (identifier$ [..prelude_module "let'"]) value body')) + (form$ (list (identifier$ ["library/lux" "let'"]) value body')) _ (form$ (list g!bind @@ -1588,7 +1588,7 @@ var)))) body (list\reverse (as_pairs bindings)))] - (return (list (form$ (list (record$ (list [(record$ (list [(tag$ [..prelude_module "wrap"]) g!wrap] [(tag$ [..prelude_module "bind"]) g!bind])) + (return (list (form$ (list (record$ (list [(record$ (list [(tag$ ["library/lux" "wrap"]) g!wrap] [(tag$ ["library/lux" "bind"]) g!bind])) body'])) monad))))) @@ -1637,7 +1637,7 @@ xs))) (macro:' #export (if tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "Picks which expression to evaluate based on a bit test value." __paragraph "(if #1 ''Oh, yeah!'' ''Aw hell naw!'')" __paragraph @@ -1745,9 +1745,9 @@ (def:''' (as_code_list expression) #Nil (-> Code Code) - (let' [type (form$ (list (tag$ [..prelude_module "Apply"]) - (identifier$ [..prelude_module "Code"]) - (identifier$ [..prelude_module "List"])))] + (let' [type (form$ (list (tag$ ["library/lux" "Apply"]) + (identifier$ ["library/lux" "Code"]) + (identifier$ ["library/lux" "List"])))] (form$ (list (text$ "lux type check") type expression)))) (def:''' (splice replace? untemplate elems) @@ -1755,7 +1755,7 @@ (-> Bit (-> Code ($' Meta Code)) ($' List Code) ($' Meta Code)) ({#1 ({#Nil - (return (tag$ [..prelude_module "Nil"])) + (return (tag$ ["library/lux" "Nil"])) (#Cons lastI inits) (do meta_monad @@ -1765,21 +1765,21 @@ _ (do meta_monad [lastO (untemplate lastI)] - (wrap (as_code_list (form$ (list (tag$ [..prelude_module "Cons"]) - (tuple$ (list lastO (tag$ [..prelude_module "Nil"]))))))))} + (wrap (as_code_list (form$ (list (tag$ ["library/lux" "Cons"]) + (tuple$ (list lastO (tag$ ["library/lux" "Nil"]))))))))} lastI)] (monad\fold meta_monad (function' [leftI rightO] ({[_ (#Form (#Cons [[_ (#Identifier ["" "~+"])] (#Cons [spliced #Nil])]))] (let' [g!in-module (form$ (list (text$ "lux in-module") - (text$ ..prelude_module) - (identifier$ [..prelude_module "list\compose"])))] + (text$ "library/lux") + (identifier$ ["library/lux" "list\compose"])))] (wrap (form$ (list g!in-module (as_code_list spliced) rightO)))) _ (do meta_monad [leftO (untemplate leftI)] - (wrap (form$ (list (tag$ [..prelude_module "Cons"]) (tuple$ (list leftO rightO))))))} + (wrap (form$ (list (tag$ ["library/lux" "Cons"]) (tuple$ (list leftO rightO))))))} leftI)) lastO inits))} @@ -1793,31 +1793,31 @@ (def:''' (untemplate_text value) #Nil (-> Text Code) - (wrap_meta (form$ (list (tag$ [..prelude_module "Text"]) (text$ value))))) + (wrap_meta (form$ (list (tag$ ["library/lux" "Text"]) (text$ value))))) (def:''' (untemplate replace? subst token) #Nil (-> Bit Text Code ($' Meta Code)) ({[_ [_ (#Bit value)]] - (return (wrap_meta (form$ (list (tag$ [..prelude_module "Bit"]) (bit$ value))))) + (return (wrap_meta (form$ (list (tag$ ["library/lux" "Bit"]) (bit$ value))))) [_ [_ (#Nat value)]] - (return (wrap_meta (form$ (list (tag$ [..prelude_module "Nat"]) (nat$ value))))) + (return (wrap_meta (form$ (list (tag$ ["library/lux" "Nat"]) (nat$ value))))) [_ [_ (#Int value)]] - (return (wrap_meta (form$ (list (tag$ [..prelude_module "Int"]) (int$ value))))) + (return (wrap_meta (form$ (list (tag$ ["library/lux" "Int"]) (int$ value))))) [_ [_ (#Rev value)]] - (return (wrap_meta (form$ (list (tag$ [..prelude_module "Rev"]) (rev$ value))))) + (return (wrap_meta (form$ (list (tag$ ["library/lux" "Rev"]) (rev$ value))))) [_ [_ (#Frac value)]] - (return (wrap_meta (form$ (list (tag$ [..prelude_module "Frac"]) (frac$ value))))) + (return (wrap_meta (form$ (list (tag$ ["library/lux" "Frac"]) (frac$ value))))) [_ [_ (#Text value)]] (return (untemplate_text value)) [#0 [_ (#Tag [module name])]] - (return (wrap_meta (form$ (list (tag$ [..prelude_module "Tag"]) (tuple$ (list (text$ module) (text$ name))))))) + (return (wrap_meta (form$ (list (tag$ ["library/lux" "Tag"]) (tuple$ (list (text$ module) (text$ name))))))) [#1 [_ (#Tag [module name])]] (let' [module' ({"" @@ -1826,7 +1826,7 @@ _ module} module)] - (return (wrap_meta (form$ (list (tag$ [..prelude_module "Tag"]) (tuple$ (list (text$ module') (text$ name)))))))) + (return (wrap_meta (form$ (list (tag$ ["library/lux" "Tag"]) (tuple$ (list (text$ module') (text$ name)))))))) [#1 [_ (#Identifier [module name])]] (do meta_monad @@ -1839,20 +1839,20 @@ (wrap [module name])} module) #let [[module name] real_name]] - (return (wrap_meta (form$ (list (tag$ [..prelude_module "Identifier"]) (tuple$ (list (text$ module) (text$ name)))))))) + (return (wrap_meta (form$ (list (tag$ ["library/lux" "Identifier"]) (tuple$ (list (text$ module) (text$ name)))))))) [#0 [_ (#Identifier [module name])]] - (return (wrap_meta (form$ (list (tag$ [..prelude_module "Identifier"]) (tuple$ (list (text$ module) (text$ name))))))) + (return (wrap_meta (form$ (list (tag$ ["library/lux" "Identifier"]) (tuple$ (list (text$ module) (text$ name))))))) [#1 [_ (#Form (#Cons [[_ (#Identifier ["" "~"])] (#Cons [unquoted #Nil])]))]] (return (form$ (list (text$ "lux type check") - (identifier$ [..prelude_module "Code"]) + (identifier$ ["library/lux" "Code"]) unquoted))) [#1 [_ (#Form (#Cons [[_ (#Identifier ["" "~!"])] (#Cons [dependent #Nil])]))]] (do meta_monad [independent (untemplate replace? subst dependent)] - (wrap (wrap_meta (form$ (list (tag$ [..prelude_module "Form"]) + (wrap (wrap_meta (form$ (list (tag$ ["library/lux" "Form"]) (untemplate_list (list (untemplate_text "lux in-module") (untemplate_text subst) independent))))))) @@ -1863,13 +1863,13 @@ [_ [meta (#Form elems)]] (do meta_monad [output (splice replace? (untemplate replace? subst) elems) - #let [[_ output'] (wrap_meta (form$ (list (tag$ [..prelude_module "Form"]) output)))]] + #let [[_ output'] (wrap_meta (form$ (list (tag$ ["library/lux" "Form"]) output)))]] (wrap [meta output'])) [_ [meta (#Tuple elems)]] (do meta_monad [output (splice replace? (untemplate replace? subst) elems) - #let [[_ output'] (wrap_meta (form$ (list (tag$ [..prelude_module "Tuple"]) output)))]] + #let [[_ output'] (wrap_meta (form$ (list (tag$ ["library/lux" "Tuple"]) output)))]] (wrap [meta output'])) [_ [_ (#Record fields)]] @@ -1883,20 +1883,20 @@ =v (untemplate replace? subst v)] (wrap (tuple$ (list =k =v))))))) fields)] - (wrap (wrap_meta (form$ (list (tag$ [..prelude_module "Record"]) (untemplate_list =fields))))))} + (wrap (wrap_meta (form$ (list (tag$ ["library/lux" "Record"]) (untemplate_list =fields))))))} [replace? token])) (macro:' #export (primitive tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Macro to treat define new primitive types." __paragraph "(primitive ''java.lang.Object'')" __paragraph "(primitive ''java.util.List'' [(primitive ''java.lang.Long'')])"))]) ({(#Cons [_ (#Text class_name)] #Nil) - (return (list (form$ (list (tag$ [..prelude_module "Primitive"]) (text$ class_name) (tag$ [..prelude_module "Nil"]))))) + (return (list (form$ (list (tag$ ["library/lux" "Primitive"]) (text$ class_name) (tag$ ["library/lux" "Nil"]))))) (#Cons [_ (#Text class_name)] (#Cons [_ (#Tuple params)] #Nil)) - (return (list (form$ (list (tag$ [..prelude_module "Primitive"]) (text$ class_name) (untemplate_list params))))) + (return (list (form$ (list (tag$ ["library/lux" "Primitive"]) (text$ class_name) (untemplate_list params))))) _ (fail "Wrong syntax for primitive")} @@ -1918,7 +1918,7 @@ state)) (macro:' #export (` tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Hygienic quasi-quotation as a macro. Unquote (~) and unquote-splice (~+) must also be used as forms." __paragraph "## All unprefixed macros will receive their parent module's prefix if imported; otherwise will receive the prefix of the module on which the quasi-quote is being used." __paragraph @@ -1928,7 +1928,7 @@ [current_module current_module_name =template (untemplate #1 current_module template)] (wrap (list (form$ (list (text$ "lux type check") - (identifier$ [..prelude_module "Code"]) + (identifier$ ["library/lux" "Code"]) =template))))) _ @@ -1936,35 +1936,35 @@ tokens)) (macro:' #export (`' tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Unhygienic quasi-quotation as a macro. Unquote (~) and unquote-splice (~+) must also be used as forms." __paragraph "(`' (def: (~ name) (function (_ (~+ args)) (~ body))))"))]) ({(#Cons template #Nil) (do meta_monad [=template (untemplate #1 "" template)] - (wrap (list (form$ (list (text$ "lux type check") (identifier$ [..prelude_module "Code"]) =template))))) + (wrap (list (form$ (list (text$ "lux type check") (identifier$ ["library/lux" "Code"]) =template))))) _ (fail "Wrong syntax for `")} tokens)) (macro:' #export (' tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Quotation as a macro." __paragraph "(' YOLO)"))]) ({(#Cons template #Nil) (do meta_monad [=template (untemplate #0 "" template)] - (wrap (list (form$ (list (text$ "lux type check") (identifier$ [..prelude_module "Code"]) =template))))) + (wrap (list (form$ (list (text$ "lux type check") (identifier$ ["library/lux" "Code"]) =template))))) _ (fail "Wrong syntax for '")} tokens)) (macro:' #export (|> tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Piping macro." __paragraph "(|> elems (list\map int\encode) (interpose '' '') (fold text\compose ''''))" __paragraph @@ -1990,7 +1990,7 @@ tokens)) (macro:' #export (<| tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Reverse piping macro." __paragraph "(<| (fold text\compose '''') (interpose '' '') (list\map int\encode) elems)" __paragraph @@ -2016,7 +2016,7 @@ (list\reverse tokens))) (def:''' (compose f g) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ "Function composition.")]) (All [a b c] (-> (-> b c) (-> a b) (-> a c))) @@ -2138,7 +2138,7 @@ (list\fold list\compose #Nil (list\reverse xs))) (macro:' #export (template tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## By specifying a pattern (with holes), and the input data to fill those holes, repeats the pattern as many times as necessary." __paragraph "(template [ ]" ..\n @@ -2269,7 +2269,7 @@ (|> n (n/% div) ("lux i64 =" 0))) (def:''' #export (not x) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Bit negation." __paragraph "(not #1) => #0" __paragraph @@ -2477,7 +2477,7 @@ type)) (macro:' #export (type tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Takes a type expression and returns it's representation as data-structure." __paragraph "(type (All [a] (Maybe (List a))))"))]) @@ -2496,7 +2496,7 @@ tokens)) (macro:' #export (: tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## The type-annotation macro." __paragraph "(: (List Int) (list +1 +2 +3))"))]) @@ -2508,7 +2508,7 @@ tokens)) (macro:' #export (:as tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## The type-coercion macro." __paragraph "(:as Dinosaur (list +1 +2 +3))"))]) @@ -2606,7 +2606,7 @@ state)) (macro:' #export (Rec tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Parameter-less recursive types." __paragraph "## A name has to be given to the whole type, to use it within its body." __paragraph @@ -2621,7 +2621,7 @@ tokens)) (macro:' #export (exec tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Sequential execution of expressions (great for side-effects)." __paragraph "(exec" ..\n @@ -2783,7 +2783,7 @@ branches)) (macro:' #export (case tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## The pattern-matching macro." ..\n "## Allows the usage of macros within the patterns to provide custom syntax." ..\n @@ -2802,7 +2802,7 @@ tokens)) (macro:' #export (^ tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Macro-expanding patterns." ..\n "## It's a special macro meant to be used with 'case'." ..\n @@ -2827,7 +2827,7 @@ (fail "Wrong syntax for ^ macro"))) (macro:' #export (^or tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Or-patterns." ..\n "## It's a special macro meant to be used with 'case'." ..\n @@ -2865,7 +2865,7 @@ #0)) (macro:' #export (let tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Creates local bindings." ..\n "## Can (optionally) use pattern-matching macros when binding." ..\n @@ -2891,7 +2891,7 @@ (fail "Wrong syntax for let"))) (macro:' #export (function tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Syntax for creating functions." ..\n "## Allows for giving the function itself a name, for the sake of recursion." ..\n @@ -2926,25 +2926,25 @@ (-> Code Code) (case code [_ (#Bit value)] - (meta_code [..prelude_module "Bit"] (bit$ value)) + (meta_code ["library/lux" "Bit"] (bit$ value)) [_ (#Nat value)] - (meta_code [..prelude_module "Nat"] (nat$ value)) + (meta_code ["library/lux" "Nat"] (nat$ value)) [_ (#Int value)] - (meta_code [..prelude_module "Int"] (int$ value)) + (meta_code ["library/lux" "Int"] (int$ value)) [_ (#Rev value)] - (meta_code [..prelude_module "Rev"] (rev$ value)) + (meta_code ["library/lux" "Rev"] (rev$ value)) [_ (#Frac value)] - (meta_code [..prelude_module "Frac"] (frac$ value)) + (meta_code ["library/lux" "Frac"] (frac$ value)) [_ (#Text value)] - (meta_code [..prelude_module "Text"] (text$ value)) + (meta_code ["library/lux" "Text"] (text$ value)) [_ (#Tag [prefix name])] - (meta_code [..prelude_module "Tag"] (` [(~ (text$ prefix)) (~ (text$ name))])) + (meta_code ["library/lux" "Tag"] (` [(~ (text$ prefix)) (~ (text$ name))])) (^or [_ (#Form _)] [_ (#Identifier _)]) code @@ -2953,7 +2953,7 @@ (|> xs (list\map process_def_meta_value) untemplate_list - (meta_code [..prelude_module "Tuple"])) + (meta_code ["library/lux" "Tuple"])) [_ (#Record kvs)] (|> kvs @@ -2962,7 +2962,7 @@ (` [(~ (process_def_meta_value k)) (~ (process_def_meta_value v))])))) untemplate_list - (meta_code [..prelude_module "Record"])) + (meta_code ["library/lux" "Record"])) )) (def:' (process_def_meta kvs) @@ -2980,7 +2980,7 @@ meta _ - (` (#.Cons [[(~ location_code) (#.Tag [..prelude_module "func-args"])] + (` (#.Cons [[(~ location_code) (#.Tag ["library/lux" "func-args"])] [(~ location_code) (#.Tuple (.list (~+ (list\map (function (_ arg) (` [(~ location_code) (#.Text (~ (text$ (code\encode arg))))])) args))))]] @@ -3007,7 +3007,7 @@ (list))) (macro:' #export (def: tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Defines global constants/functions." ..\n "(def: (rejoin_pair pair)" ..\n @@ -3090,7 +3090,7 @@ base)) (macro:' #export (macro: tokens) - (list [(tag$ [..prelude_module "doc"]) + (list [(tag$ ["library/lux" "doc"]) (text$ ($_ "lux text concat" "## Macro-definition macro." ..\n "(macro: #export (name_of tokens)" ..\n @@ -5431,7 +5431,7 @@ {#.doc (doc "Given an identifier or a tag, gives back a 2 tuple with the prefix and name parts, both as Text." (name_of #.doc) "=>" - [..prelude_module "doc"])} + ["library/lux" "doc"])} (case tokens (^template [] [(^ (list [_ ( [prefix name])])) @@ -5439,7 +5439,7 @@ ([#Identifier] [#Tag]) _ - (fail (..wrong_syntax_error [..prelude_module "name_of"])))) + (fail (..wrong_syntax_error ["library/lux" "name_of"])))) (def: (get_scope_type_vars state) (Meta (List Nat)) -- cgit v1.2.3