projects
/
matthijs
/
master-project
/
cλash.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Add some newlines in the output.
[matthijs/master-project/cλash.git]
/
Adders.hs
diff --git
a/Adders.hs
b/Adders.hs
index ac93a3366db359f3fc368467fe7280320aece926..4745d8cd66b1984ae6e119f2e1e5399f38110ea2 100644
(file)
--- a/
Adders.hs
+++ b/
Adders.hs
@@
-16,6
+16,10
@@
show_add f = do print ("Sum: " ++ (displaysigs s)); print ("Carry: " ++ (displ
b = [Low, Low, Low, High]
(s, c) = f (a, b)
+mux2 :: Bit -> (Bit, Bit) -> Bit
+mux2 Low (a, b) = a
+mux2 High (a, b) = b
+
-- Not really an adder, but this is nice minimal hardware description
wire :: Bit -> Bit
wire a = a