--- rec_adder :: ([Bit], [Bit]) -> ([Bit], Bit)
---
--- rec_adder ([], []) = ([], Low)
--- rec_adder ((a:as), (b:bs)) =
--- (s : rest, cout)
--- where
--- (rest, cin) = rec_adder (as, bs)
--- (s, cout) = full_adder (a, b, cin)
---
--- foo = id
--- add, sub :: Int -> Int -> Int
--- add a b = a + b
--- sub a b = a - b
---
--- highordtest = \x ->
--- let s = foo x
--- in
--- case s of
--- (a, b) ->
--- case a of
--- High -> add
--- Low -> let
--- op' = case b of
--- High -> sub
--- Low -> \c d -> c
--- in
--- \c d -> op' d c
-
-functiontest :: TFVec D4 Bit -> Bit
-functiontest = \v -> let r = head v in r
-
+rec_adder :: ([Bit], [Bit]) -> ([Bit], Bit)
+
+rec_adder ([], []) = ([], Low)
+rec_adder ((a:as), (b:bs)) =
+ (s : rest, cout)
+ where
+ (rest, cin) = rec_adder (as, bs)
+ (s, cout) = full_adder (a, b, cin)
+
+foo = id
+add, sub :: Int -> Int -> Int
+add a b = a + b
+sub a b = a - b
+
+highordtest = \x ->
+ let s = foo x
+ in
+ case s of
+ (a, b) ->
+ case a of
+ High -> add
+ Low -> let
+ op' = case b of
+ High -> sub
+ Low -> \c d -> c
+ in
+ \c d -> op' d c
+
+xand a b = hwand a b
+
+functiontest :: TFVec D3 (TFVec D4 Bit) -> TFVec D12 Bit
+functiontest = \v -> let r = concat v in r
+
+functiontest2 :: SizedInt D8 -> SizedInt D7
+functiontest2 = \a -> let r = Data.SizedInt.resize a in r
+
+xhwnot x = hwnot x
+
+maptest :: TFVec D4 Bit -> TFVec D4 Bit
+maptest = \v -> let r = map xhwnot v in r
+
+highordtest2 = \a b ->
+ case a of
+ High -> \c d -> d
+ Low -> let
+ op' :: Bit -> Bit -> Bit
+ op' = case b of
+ High -> \c d -> d
+ Low -> \c d -> c
+ in
+ \c d -> op' d c