summaryrefslogtreecommitdiff
path: root/src/CHAD
diff options
context:
space:
mode:
authorTom Smeding <t.j.smeding@uu.nl>2024-10-07 14:34:27 +0200
committerTom Smeding <t.j.smeding@uu.nl>2024-10-07 14:34:27 +0200
commit72eddb67bb6f048fc2076184be3a32169026a832 (patch)
tree2f5ca7511a798d7329b12d499f4dea7239b39c50 /src/CHAD
parent948cae3ca7279040627db393e4372a668f8a22f7 (diff)
Towards a test suite
Diffstat (limited to 'src/CHAD')
-rw-r--r--src/CHAD/Types.hs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/CHAD/Types.hs b/src/CHAD/Types.hs
index 0b32393..0b73a3a 100644
--- a/src/CHAD/Types.hs
+++ b/src/CHAD/Types.hs
@@ -4,6 +4,7 @@
module CHAD.Types where
import AST.Types
+import Data
type family D1 t where
@@ -63,3 +64,7 @@ d2 (STScal t) = case t of
STF64 -> STScal STF64
STBool -> STNil
d2 STAccum{} = error "Accumulators not allowed in input program"
+
+d2e :: SList STy env -> SList STy (D2E env)
+d2e SNil = SNil
+d2e (SCons t ts) = SCons (d2 t) (d2e ts)