about summary refs log tree commit diff stats
path: root/apps/advent2020/5b.mu
diff options
context:
space:
mode:
authorKartik Agaram <vc@akkartik.com>2021-02-07 00:17:17 -0800
committerKartik Agaram <vc@akkartik.com>2021-02-07 00:20:29 -0800
commit74f1512ff113cf35706af57e9d40c78b7d77f49e (patch)
tree7c7acb23e1a26387117e464ec6ab01126dbc8ae8 /apps/advent2020/5b.mu
parent6c4c25555c7df0d78ad41c813345f63cae1819de (diff)
downloadmu-74f1512ff113cf35706af57e9d40c78b7d77f49e.tar.gz
7690
Convert comments about magic constants into metadata.
Diffstat (limited to 'apps/advent2020/5b.mu')
-rw-r--r--apps/advent2020/5b.mu6
1 files changed, 3 insertions, 3 deletions
diff --git a/apps/advent2020/5b.mu b/apps/advent2020/5b.mu
index 215b0a66..fbc0d618 100644
--- a/apps/advent2020/5b.mu
+++ b/apps/advent2020/5b.mu
@@ -20,7 +20,7 @@ fn main -> _/ebx: int {
     read-line-from-real-keyboard line
     # if line is empty (not even a newline), quit
     var done?/eax: boolean <- stream-empty? line
-    compare done?, 0  # false
+    compare done?, 0/false
     break-if-!=
     # process line
     var seat-id/eax: int <- convert-from-binary line
@@ -63,12 +63,12 @@ fn convert-from-binary in: (addr stream byte) -> _/eax: int {
     var c/eax: byte <- read-byte in
     var bit/edx: int <- copy 0
     {
-      compare c, 0x42  # 'B'
+      compare c, 0x42/B
       break-if-!=
       bit <- copy 1
     }
     {
-      compare c, 0x52  # 'R'
+      compare c, 0x52/R
       break-if-!=
       bit <- copy 1
     }