aboutsummaryrefslogtreecommitdiff
path: root/lux-r/source/program.lux
diff options
context:
space:
mode:
authorEduardo Julian2022-03-14 06:14:57 -0400
committerEduardo Julian2022-03-14 06:14:57 -0400
commit4965597043aca57a05760113f1851e96dad1eaf8 (patch)
tree8126d3e6394e38bc52918eea95a67546350bb95e /lux-r/source/program.lux
parentcfd438517a46e025b15345e3570b02f5ea6165c0 (diff)
Leaner syntax for the "for" macro.
Diffstat (limited to 'lux-r/source/program.lux')
-rw-r--r--lux-r/source/program.lux182
1 files changed, 91 insertions, 91 deletions
diff --git a/lux-r/source/program.lux b/lux-r/source/program.lux
index a9908b445..570a52b4e 100644
--- a/lux-r/source/program.lux
+++ b/lux-r/source/program.lux
@@ -1,72 +1,72 @@
(.using
- [lux "*"
- [program {"+" program:}]
- ["[0]" ffi]
- ["[0]" debug]
- [abstract
- ["[0]" monad {"+" do}]]
- [control
- [pipe {"+" exec> case> new>}]
- ["[0]" maybe]
- ["[0]" try {"+" Try}]
- ["[0]" exception {"+" exception:}]
- ["[0]" io {"+" IO io}]
- [concurrency
- ["[0]" promise {"+" Promise}]]
- [parser
- ["<[0]>" code]]]
- [data
- ["[0]" text ("[1]#[0]" hash)
- ["%" format {"+" format}]
- [encoding
- ["[0]" utf8]]]
- [collection
- ["[0]" array {"+" Array}]]]
- ["[0]" macro
- [syntax {"+" syntax:}]
- ["[0]" template]
- ["[0]" code]]
- [math
- [number {"+" hex}
- ["n" nat]
- ["[0]" i64]]]
- ["[0]" world "_"
- ["[0]" file]
- ["[1]/[0]" program]]
- ["@" target
- ["_" r]]
- [tool
- [compiler
- [phase {"+" Operation Phase}]
- [reference
- [variable {"+" Register}]]
- [language
- [lux
- [program {"+" Program}]
- [generation {"+" Context Host}]
- ["[0]" synthesis]
- [analysis
- [macro {"+" Expander}]]
- [phase
- ["[0]" extension {"+" Extender Handler}
- ["[1]/[0]" bundle]
- ["[0]" analysis "_"
- ["[1]" r]]
- ["[0]" generation "_"
- ["[1]" r]]]
- [generation
- ["[0]" reference]
- ["[0]" r
- ["[0]" runtime]]]]]]
- [default
- ["[0]" platform {"+" Platform}]]
- [meta
- ["[0]" packager "_"
- ["[1]" script]]]]]]
- [program
- ["/" compositor
- ["[1][0]" cli]
- ["[1][0]" static]]])
+ [lux "*"
+ [program {"+" program:}]
+ ["[0]" ffi]
+ ["[0]" debug]
+ [abstract
+ ["[0]" monad {"+" do}]]
+ [control
+ [pipe {"+" exec> case> new>}]
+ ["[0]" maybe]
+ ["[0]" try {"+" Try}]
+ ["[0]" exception {"+" exception:}]
+ ["[0]" io {"+" IO io}]
+ [concurrency
+ ["[0]" promise {"+" Promise}]]
+ [parser
+ ["<[0]>" code]]]
+ [data
+ ["[0]" text ("[1]#[0]" hash)
+ ["%" format {"+" format}]
+ [encoding
+ ["[0]" utf8]]]
+ [collection
+ ["[0]" array {"+" Array}]]]
+ ["[0]" macro
+ [syntax {"+" syntax:}]
+ ["[0]" template]
+ ["[0]" code]]
+ [math
+ [number {"+" hex}
+ ["n" nat]
+ ["[0]" i64]]]
+ ["[0]" world "_"
+ ["[0]" file]
+ ["[1]/[0]" program]]
+ ["@" target
+ ["_" r]]
+ [tool
+ [compiler
+ [phase {"+" Operation Phase}]
+ [reference
+ [variable {"+" Register}]]
+ [language
+ [lux
+ [program {"+" Program}]
+ [generation {"+" Context Host}]
+ ["[0]" synthesis]
+ [analysis
+ [macro {"+" Expander}]]
+ [phase
+ ["[0]" extension {"+" Extender Handler}
+ ["[1]/[0]" bundle]
+ ["[0]" analysis "_"
+ ["[1]" r]]
+ ["[0]" generation "_"
+ ["[1]" r]]]
+ [generation
+ ["[0]" reference]
+ ["[0]" r
+ ["[0]" runtime]]]]]]
+ [default
+ ["[0]" platform {"+" Platform}]]
+ [meta
+ ["[0]" packager "_"
+ ["[1]" script]]]]]]
+ [program
+ ["/" compositor
+ ["[1][0]" cli]
+ ["[1][0]" static]]])
(ffi.import: java/lang/String)
@@ -552,29 +552,29 @@
(Program _.Expression _.Expression)
(_.apply/2 program [(runtime.lux::program_args (_.commandArgs/0 [])) _.null]))
-(for [@.old
- (def: extender
- Extender
- ... TODO: Stop relying on coercions ASAP.
- (<| (:as Extender)
- (function (@self handler))
- (:as Handler)
- (function (@self name phase))
- (:as Phase)
- (function (@self archive parameters))
- (:as Operation)
- (function (@self state))
- (:as Try)
- try.trusted
- (:as Try)
- (exec
- ("lux io log" "TODO: Extender")
- {try.#Failure "TODO: Extender"})))
-
- @.r
- (def: (extender handler)
- Extender
- (:expected handler))])
+(for @.old
+ (def: extender
+ Extender
+ ... TODO: Stop relying on coercions ASAP.
+ (<| (:as Extender)
+ (function (@self handler))
+ (:as Handler)
+ (function (@self name phase))
+ (:as Phase)
+ (function (@self archive parameters))
+ (:as Operation)
+ (function (@self state))
+ (:as Try)
+ try.trusted
+ (:as Try)
+ (exec
+ ("lux io log" "TODO: Extender")
+ {try.#Failure "TODO: Extender"})))
+
+ @.r
+ (def: (extender handler)
+ Extender
+ (:expected handler)))
(def: (declare_success! _)
(-> Any (Promise Any))