aboutsummaryrefslogtreecommitdiff
path: root/projects
diff options
context:
space:
mode:
authorYuchen Pei <me@ypei.me>2017-12-19 20:43:40 +0100
committerYuchen Pei <me@ypei.me>2017-12-19 20:43:40 +0100
commit4e2796decd37f5b07a1be0da08aaa6f5b28142b5 (patch)
tree0b37c1543f20239dbf51bece37b7cdc36f62cbcb /projects
parent4d095367dfd58825a4d8ad17c92c146993add538 (diff)
testing checkpoint
Diffstat (limited to 'projects')
-rwxr-xr-xprojects/06/Assemblerbin65896 -> 22320 bytes
-rw-r--r--projects/06/Assembler.hs8
-rw-r--r--projects/06/Assembler.obin76496 -> 9560 bytes
3 files changed, 5 insertions, 3 deletions
diff --git a/projects/06/Assembler b/projects/06/Assembler
index 7cd3b78..b19cc81 100755
--- a/projects/06/Assembler
+++ b/projects/06/Assembler
Binary files differ
diff --git a/projects/06/Assembler.hs b/projects/06/Assembler.hs
index 28f506d..3583121 100644
--- a/projects/06/Assembler.hs
+++ b/projects/06/Assembler.hs
@@ -88,6 +88,8 @@ parseCode code = mconcat $ parseLine (addSyms codeWithoutJunk 0 16 initTable) <$
where codeWithoutJunk = stripJunk code
codeWithoutLabels = stripLabels codeWithoutJunk
-main = do
- code <- getContents
- putStr $ parseCode code
+code0 = "// This file is part of www.nand2tetris.org\n// and the book \"The Elements of Computing Systems\"\n// by Nisan and Schocken, MIT Press.\n// File name: projects/06/add/Add.asm\n\n// Computes R0 = 2 + 3 (R0 refers to RAM[0])\n\n@2\nD=A\n@3\nD=D+A\n@0\nM=D"
+
+--main = do
+ --code <- getContents
+ --putStr $ parseCode code
diff --git a/projects/06/Assembler.o b/projects/06/Assembler.o
index 09d8785..c10385e 100644
--- a/projects/06/Assembler.o
+++ b/projects/06/Assembler.o
Binary files differ