summaryrefslogtreecommitdiff
path: root/src/main.lisp
diff options
context:
space:
mode:
authorbd <bdunahu@operationnull.com>2025-04-09 23:45:16 -0400
committerbd <bdunahu@operationnull.com>2025-04-09 23:45:16 -0400
commite50d44464db7eb8e1c20755c862466ac8f7419b0 (patch)
tree495e62cb00fbb67f418c50cb96074fb638126877 /src/main.lisp
parentce80845b5cb5b473327e4e561342490576d83a90 (diff)
Properly maintain a hashmap of labels, lots of minor code cleanups
Diffstat (limited to 'src/main.lisp')
-rw-r--r--src/main.lisp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/main.lisp b/src/main.lisp
index 9180d57..be9f69a 100644
--- a/src/main.lisp
+++ b/src/main.lisp
@@ -1,6 +1,6 @@
(in-package #:rva)
-(defparameter *banner*
+(defvar *banner*
" _/_/ _/_/
_/ _/
_/ _/ _/_/ _/ _/ _/_/_/ _/
@@ -30,7 +30,7 @@ _/_/ _/_/ "
(print-splash)
(let* ((args (clingon:command-arguments cmd))
(file (car args))
- (emit? (not (clingon:getopt cmd :parse))))
+ (emit? (not (clingon:getopt cmd :parse))))
(cond
;; complain about num arguments
((/= (length args) 1) (error "Wrong number of arguments.~%"))
@@ -38,8 +38,9 @@ _/_/ _/_/ "
(error "The file is not an asm source code file.~%"))
(t (let ((str (uiop:read-file-string file)))
(if str
- (progn (pprint (esrap:parse 'parse:text (string-upcase str)))
+ (progn (pprint (esrap:parse 'parse:text (string-upcase str)))
(terpri)
+ (maphash #'(lambda (k v) (format t "~A => ~A~%" k v)) util:label-table)
(format t "---~%"))
(error "The file does not exist, or it could not be opened.~%"))
(format t "Nitimur in Vetitum~%"))))))