aboutsummaryrefslogtreecommitdiff
path: root/src/Data
diff options
context:
space:
mode:
authorTom Smeding <tom@tomsmeding.com>2024-04-17 10:22:01 +0200
committerTom Smeding <tom@tomsmeding.com>2024-04-17 10:22:01 +0200
commite7df04c53ee43603d4a75bf31c7bddae1575366a (patch)
treea717d11af7c0cf0a1f7ee6b2636861ed7c0bff26 /src/Data
parent0711a3981b56bbe063aa73d5ac8da61b6901c9b2 (diff)
Strict fields in data instances
Diffstat (limited to 'src/Data')
-rw-r--r--src/Data/Array/Nested/Internal.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Data/Array/Nested/Internal.hs b/src/Data/Array/Nested/Internal.hs
index bfcb760..e470907 100644
--- a/src/Data/Array/Nested/Internal.hs
+++ b/src/Data/Array/Nested/Internal.hs
@@ -117,7 +117,7 @@ newtype instance Mixed sh () = M_Nil (XArray sh ()) -- no content, orthotope op
deriving (Show)
-- etc.
-data instance Mixed sh (a, b) = M_Tup2 (Mixed sh a) (Mixed sh b)
+data instance Mixed sh (a, b) = M_Tup2 !(Mixed sh a) !(Mixed sh b)
deriving instance (Show (Mixed sh a), Show (Mixed sh b)) => Show (Mixed sh (a, b))
-- etc.
@@ -137,10 +137,10 @@ newtype instance MixedVecs s sh Double = MV_Double (VS.MVector s Double)
newtype instance MixedVecs s sh () = MV_Nil (VS.MVector s ()) -- no content, MVector optimises this
-- etc.
-data instance MixedVecs s sh (a, b) = MV_Tup2 (MixedVecs s sh a) (MixedVecs s sh b)
+data instance MixedVecs s sh (a, b) = MV_Tup2 !(MixedVecs s sh a) !(MixedVecs s sh b)
-- etc.
-data instance MixedVecs s sh1 (Mixed sh2 a) = MV_Nest (IxX sh2) (MixedVecs s (sh1 ++ sh2) a)
+data instance MixedVecs s sh1 (Mixed sh2 a) = MV_Nest !(IxX sh2) !(MixedVecs s (sh1 ++ sh2) a)
-- | Tree giving the shape of every array component.