aboutsummaryrefslogtreecommitdiff
path: root/src/Data
diff options
context:
space:
mode:
authorTom Smeding <tom@tomsmeding.com>2024-05-31 08:56:11 +0200
committerTom Smeding <tom@tomsmeding.com>2024-05-31 08:58:49 +0200
commitdf658b3aaea94e1bae0b332c264c1b3b18fe017b (patch)
treefccc1945f02a376e9bf92e6a52cfd4b59824b23c /src/Data
parent67236301372bc151e8b425465b47a057fa3282f6 (diff)
Fix comment in Nested.Shape
Diffstat (limited to 'src/Data')
-rw-r--r--src/Data/Array/Nested/Internal/Shape.hs7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/Data/Array/Nested/Internal/Shape.hs b/src/Data/Array/Nested/Internal/Shape.hs
index 664a724..4163007 100644
--- a/src/Data/Array/Nested/Internal/Shape.hs
+++ b/src/Data/Array/Nested/Internal/Shape.hs
@@ -328,9 +328,7 @@ applyPermShS = coerce (applyPermS @SNat)
-- | An index into a shape-typed array.
--
-- For convenience, this contains regular 'Int's instead of bounded integers
--- (traditionally called \"@Fin@\"). Note that because the shape of a
--- shape-typed array is known statically, you can also retrieve the array shape
--- from a 'KnownShape' dictionary.
+-- (traditionally called \"@Fin@\").
type role IxS nominal representational
type IxS :: [Nat] -> Type -> Type
newtype IxS sh i = IxS (ListS sh (Const i))
@@ -374,6 +372,9 @@ ixCvtSX (n :.$ sh) = n :.% ixCvtSX sh
-- | The shape of a shape-typed array given as a list of 'SNat' values.
+--
+-- Note that because the shape of a shape-typed array is known statically, you
+-- can also retrieve the array shape from a 'KnownShS' dictionary.
type role ShS nominal
type ShS :: [Nat] -> Type
newtype ShS sh = ShS (ListS sh SNat)