aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authors-ol <s-ol@users.noreply.github.com>2020-05-08 12:18:45 +0000
committers-ol <s+removethis@s-ol.nu>2025-03-02 14:23:21 +0000
commit62e3c3866c01ff6ac75aaba06fdc1fbf8ab5f824 (patch)
tree796e58784c759c9d70691a8dbe9167e92ae38ff9
parentadd shorthands for builtin primitives to Primitive (diff)
downloadalive-62e3c3866c01ff6ac75aaba06fdc1fbf8ab5f824.tar.gz
alive-62e3c3866c01ff6ac75aaba06fdc1fbf8ab5f824.zip
more internal doc fixes
-rw-r--r--alv/base/fndef.moon2
-rw-r--r--alv/result/base.moon6
-rw-r--r--alv/result/evt.moon8
-rw-r--r--alv/result/io.moon4
-rw-r--r--alv/result/sig.moon8
-rw-r--r--alv/type.moon2
6 files changed, 15 insertions, 15 deletions
diff --git a/alv/base/fndef.moon b/alv/base/fndef.moon
index f8858d3..836294d 100644
--- a/alv/base/fndef.moon
+++ b/alv/base/fndef.moon
@@ -1,5 +1,5 @@
----
--- user-function definition (`fndef`).
+-- User-function definition (`fndef`).
--
-- When called, expands to its body with params bound to the fn arguments (see
-- `invoke.fn_invoke`).
diff --git a/alv/result/base.moon b/alv/result/base.moon
index bbbbeac..6accb1e 100644
--- a/alv/result/base.moon
+++ b/alv/result/base.moon
@@ -27,8 +27,8 @@ class Result
__tostring: => "<#{@type}#{@metatype} #{@type\pp @value}>"
__inherited: (cls) => cls.__base.__tostring or= @__tostring
- --- the type name of this Result's value.
- -- @tfield string type
+ --- the type of this Result's value.
+ -- @tfield type.Type type
--- the metatype string for this Result.
--
@@ -59,7 +59,7 @@ class Result
--- construct a new Result.
--
-- @classmethod
- -- @tparam string type the type name
+ -- @tparam type.Type type the type
-- @tparam ?table meta the `meta` table
new: (@type, @meta={}) =>
diff --git a/alv/result/evt.moon b/alv/result/evt.moon
index fdec85e..bab502c 100644
--- a/alv/result/evt.moon
+++ b/alv/result/evt.moon
@@ -19,7 +19,7 @@ class EvtStream extends Result
-- Returns `events` if `dirty`, or an empty table otherwise.
-- Asserts `@type == type` if `type` is given.
--
- -- @tparam[opt] string type the type to check for
+ -- @tparam[opt] type.Type type the type to check for
-- @tparam[optchain] string msg message to throw if type don't match
-- @treturn {any,...} `events`
unwrap: (type, msg) =>
@@ -37,8 +37,8 @@ class EvtStream extends Result
__call: (...) => @unwrap ...
__tostring: => "<#{@type}#{@metatype} #{@type\pp @value}>"
- --- the type name of this Result's value.
- -- @tfield string type
+ --- the type of this Result's value.
+ -- @tfield type.Type type
--- the metatype string for this Result.
-- @tfield string metatype (`!`)
@@ -78,7 +78,7 @@ class EvtStream extends Result
--- construct a new EvtStream.
--
-- @classmethod
- -- @tparam string type the type name
+ -- @tparam type.Type type the type
new: (type) => super type
{
diff --git a/alv/result/io.moon b/alv/result/io.moon
index b12322c..f68f672 100644
--- a/alv/result/io.moon
+++ b/alv/result/io.moon
@@ -18,10 +18,10 @@ class IOStream extends EvtStream
--- construct a new IOStream.
--
-- Must prepare the instance for `dirty` to be called.
- -- The super-constructor should be called to set `Stream.type`.
+ -- The super-constructor should be called to set `Result.type`.
--
-- @classmethod
- -- @tparam string type the typename of this stream.
+ -- @tparam type.Type type the type of this stream.
new: (type) => super type
--- create a mutable copy of this stream.
diff --git a/alv/result/sig.moon b/alv/result/sig.moon
index 8ca59b7..73f06d1 100644
--- a/alv/result/sig.moon
+++ b/alv/result/sig.moon
@@ -19,7 +19,7 @@ class SigStream extends Result
--
-- Asserts `@type == type` if `type` is given.
--
- -- @tparam[opt] string type the type to check for
+ -- @tparam[opt] type.Type type the type to check for
-- @tparam[optchain] string msg message to throw if type don't match
-- @treturn any `value`
unwrap: (type, msg) =>
@@ -43,8 +43,8 @@ class SigStream extends Result
-- Compares two `SigStream`s by comparing their types and their Lua values.
__eq: (other) => other.type == @type and other.value == @value
- --- the type name of this Result's value.
- -- @tfield string type
+ --- the type of this Result's value.
+ -- @tfield type.Type type
--- the metatype string for this Result.
-- @tfield string metatype (`~`)
@@ -82,7 +82,7 @@ class SigStream extends Result
--- construct a new SigStream.
--
-- @classmethod
- -- @tparam string type the type name
+ -- @tparam type.Type type the type
-- @tparam any value the Lua value to be accessed through `unwrap`
new: (type, @value) => super type
diff --git a/alv/type.moon b/alv/type.moon
index 779cbe5..8a3708b 100644
--- a/alv/type.moon
+++ b/alv/type.moon
@@ -1,5 +1,5 @@
-----
---- Type definition classes
+--- Type definitions (`type.Type` and implementations).
--
-- @module type
import opairs from require 'alv.util'