aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/documentation/lux/meta/macro/syntax
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib/source/documentation/lux/meta/macro/syntax')
-rw-r--r--stdlib/source/documentation/lux/meta/macro/syntax/check.lux23
-rw-r--r--stdlib/source/documentation/lux/meta/macro/syntax/declaration.lux28
-rw-r--r--stdlib/source/documentation/lux/meta/macro/syntax/definition.lux31
-rw-r--r--stdlib/source/documentation/lux/meta/macro/syntax/export.lux22
-rw-r--r--stdlib/source/documentation/lux/meta/macro/syntax/input.lux25
-rw-r--r--stdlib/source/documentation/lux/meta/macro/syntax/type/variable.lux25
6 files changed, 154 insertions, 0 deletions
diff --git a/stdlib/source/documentation/lux/meta/macro/syntax/check.lux b/stdlib/source/documentation/lux/meta/macro/syntax/check.lux
new file mode 100644
index 000000000..c96bf0cde
--- /dev/null
+++ b/stdlib/source/documentation/lux/meta/macro/syntax/check.lux
@@ -0,0 +1,23 @@
+(.require
+ [library
+ [lux (.except char)
+ ["$" documentation]
+ [data
+ [text
+ ["%" \\format (.only format)]]
+ [collection
+ ["[0]" list]]]]]
+ [\\library
+ ["[0]" /]])
+
+(.def .public documentation
+ (.List $.Module)
+ ($.module /._
+ ""
+ [($.default /.equivalence)
+ ($.default /.format)
+ ($.default /.parser)
+
+ ($.documentation /.Check
+ "A type annotation for an expression.")]
+ []))
diff --git a/stdlib/source/documentation/lux/meta/macro/syntax/declaration.lux b/stdlib/source/documentation/lux/meta/macro/syntax/declaration.lux
new file mode 100644
index 000000000..fd9fe1a58
--- /dev/null
+++ b/stdlib/source/documentation/lux/meta/macro/syntax/declaration.lux
@@ -0,0 +1,28 @@
+(.require
+ [library
+ [lux (.except char)
+ ["$" documentation]
+ [data
+ [text
+ ["%" \\format (.only format)]]
+ [collection
+ ["[0]" list]]]]]
+ [\\library
+ ["[0]" /]])
+
+(.def .public documentation
+ (.List $.Module)
+ ($.module /._
+ ""
+ [($.default /.equivalence)
+ ($.default /.format)
+
+ ($.documentation /.Declaration
+ "A declaration for either a constant or a function.")
+
+ ($.documentation /.parser
+ "A parser for declaration syntax."
+ ["Such as:"
+ quux
+ (foo bar baz)])]
+ []))
diff --git a/stdlib/source/documentation/lux/meta/macro/syntax/definition.lux b/stdlib/source/documentation/lux/meta/macro/syntax/definition.lux
new file mode 100644
index 000000000..cf4b3225f
--- /dev/null
+++ b/stdlib/source/documentation/lux/meta/macro/syntax/definition.lux
@@ -0,0 +1,31 @@
+(.require
+ [library
+ [lux (.except Definition)
+ ["$" documentation]
+ [data
+ [text
+ ["%" \\format (.only format)]]
+ [collection
+ ["[0]" list]]]]]
+ [\\library
+ ["[0]" /]])
+
+(.def .public documentation
+ (.List $.Module)
+ ($.module /._
+ ""
+ [($.default /.equivalence)
+ ($.default /.lacks_type)
+ ($.default /.format)
+
+ ($.documentation /.Definition
+ "Syntax for a constant definition.")
+
+ ($.documentation /.parser
+ "A reader that first macro-expands and then analyses the input Code, to ensure it is a definition."
+ [(parser compiler)])
+
+ ($.documentation /.typed
+ "Only works for typed definitions."
+ [(typed compiler)])]
+ []))
diff --git a/stdlib/source/documentation/lux/meta/macro/syntax/export.lux b/stdlib/source/documentation/lux/meta/macro/syntax/export.lux
new file mode 100644
index 000000000..6d23bc8b9
--- /dev/null
+++ b/stdlib/source/documentation/lux/meta/macro/syntax/export.lux
@@ -0,0 +1,22 @@
+(.require
+ [library
+ [lux (.except char)
+ ["$" documentation]
+ [data
+ [text
+ ["%" \\format (.only format)]]
+ [collection
+ ["[0]" list]]]]]
+ [\\library
+ ["[0]" /]])
+
+(.def .public documentation
+ (.List $.Module)
+ ($.module /._
+ "Syntax for marking a definition as an export."
+ [($.default /.default_policy)
+
+ ($.documentation /.parser
+ ""
+ [(parser un_exported)])]
+ []))
diff --git a/stdlib/source/documentation/lux/meta/macro/syntax/input.lux b/stdlib/source/documentation/lux/meta/macro/syntax/input.lux
new file mode 100644
index 000000000..77a6b7cac
--- /dev/null
+++ b/stdlib/source/documentation/lux/meta/macro/syntax/input.lux
@@ -0,0 +1,25 @@
+(.require
+ [library
+ [lux (.except char)
+ ["$" documentation]
+ [data
+ [text
+ ["%" \\format (.only format)]]
+ [collection
+ ["[0]" list]]]]]
+ [\\library
+ ["[0]" /]])
+
+(.def .public documentation
+ (.List $.Module)
+ ($.module /._
+ ""
+ [($.default /.equivalence)
+ ($.default /.format)
+
+ ($.documentation /.Input
+ "The common typed-argument syntax used by many macros.")
+
+ ($.documentation /.parser
+ "Parser for the common typed-argument syntax used by many macros.")]
+ []))
diff --git a/stdlib/source/documentation/lux/meta/macro/syntax/type/variable.lux b/stdlib/source/documentation/lux/meta/macro/syntax/type/variable.lux
new file mode 100644
index 000000000..c29df1817
--- /dev/null
+++ b/stdlib/source/documentation/lux/meta/macro/syntax/type/variable.lux
@@ -0,0 +1,25 @@
+(.require
+ [library
+ [lux (.except char)
+ ["$" documentation]
+ [data
+ [text
+ ["%" \\format (.only format)]]
+ [collection
+ ["[0]" list]]]]]
+ [\\library
+ ["[0]" /]])
+
+(.def .public documentation
+ (.List $.Module)
+ ($.module /._
+ ""
+ [($.default /.equivalence)
+ ($.default /.format)
+
+ ($.documentation /.Variable
+ "A variable's name.")
+
+ ($.documentation /.parser
+ "Parser for the common type variable/parameter used by many macros.")]
+ []))