aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/documentation/lux/static.lux
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--stdlib/source/documentation/lux/static.lux70
1 files changed, 70 insertions, 0 deletions
diff --git a/stdlib/source/documentation/lux/static.lux b/stdlib/source/documentation/lux/static.lux
new file mode 100644
index 000000000..654409252
--- /dev/null
+++ b/stdlib/source/documentation/lux/static.lux
@@ -0,0 +1,70 @@
+(.module:
+ [library
+ [lux (#- nat int rev)
+ ["$" documentation (#+ documentation:)]
+ [data
+ [text
+ ["%" format (#+ format)]]
+ [collection
+ ["." list]]]]]
+ [\\library
+ ["." /]])
+
+(template [<name> <type>]
+ [(documentation: <name>
+ ""
+ [(<name>
+ (: <type>
+ (value generating expression)))])]
+
+ [/.nat .Nat]
+ [/.int .Int]
+ [/.rev .Rev]
+ [/.frac .Frac]
+ [/.text .Text]
+ )
+
+(documentation: /.literal
+ ""
+ [(/.literal
+ (: (-> ??? Code)
+ format)
+ (: ???
+ (value generating expression)))])
+
+(template [<name> <type>]
+ [(documentation: <name>
+ ""
+ [(: <type>
+ (<name>))])]
+
+ [/.random_nat .Nat]
+ [/.random_int .Int]
+ [/.random_rev .Rev]
+ [/.random_frac .Frac]
+ )
+
+(documentation: /.random
+ ""
+ [(/.random
+ (: (-> ??? Code)
+ format)
+ (: (Random ???)
+ (random data generator)))])
+
+(.def: .public documentation
+ (.List $.Module)
+ ($.module /._
+ ""
+ [..nat
+ ..int
+ ..rev
+ ..frac
+ ..text
+ ..literal
+ ..random_nat
+ ..random_int
+ ..random_rev
+ ..random_frac
+ ..random]
+ []))