From: plugd Date: Mon, 11 May 2020 12:45:05 +0000 (+0200) Subject: Tiny changes, made note of bug in SPL. X-Git-Url: https://thelambdalab.xyz/gitweb/index.cgi?a=commitdiff_plain;h=76daa637ffa61e0fd8532850272eb3d051eff48f;p=jars.git Tiny changes, made note of bug in SPL. --- diff --git a/NOTES.org b/NOTES.org index 00eceb7..9239397 100644 --- a/NOTES.org +++ b/NOTES.org @@ -1,5 +1,9 @@ #+TITLE: Development notes for Corewar +* MARS + +** TODO Debug SPL instruction behaviour. + * Load file parsing ** DONE Use strings for program names diff --git a/koth.scm b/koth.scm index a9c1a84..45e4bb8 100644 --- a/koth.scm +++ b/koth.scm @@ -227,10 +227,9 @@ (if (null? rankings) (print "No warriors on hill!") (begin - (print rankings) (print "Warrior" "\t" "Score") (print "-=-=-=-" "\t" "=-=-=") - (for-each (lambda (r) (print (car r) "\t" (cadr r))) rankings))))) + (for-each (lambda (r) (print (car r) "\t\t" (cadr r))) rankings))))) ((hill-dir challenger-file) (challenge hill-dir challenger-file)) (else diff --git a/parser.scm b/parser.scm index f116033..c112cf9 100644 --- a/parser.scm +++ b/parser.scm @@ -15,7 +15,7 @@ (newline-irx (irregex "^\n")) (comma-irx (irregex "^,")) (period-irx (irregex "^\\.")) - (redcode-irx (irregex "^;redcode\n")) + (redcode-irx (irregex "^;redcode.*\n")) (name-start-irx (irregex "^;[ \t]*name ")) (name-irx (irregex "^[^\n]*")) (author-start-irx (irregex "^;[ \t]*author "))