diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2021-07-07 01:05:52 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2021-07-07 07:13:16 -0700 |
commit | ef73cb78f15839cf0254ead273e0d1eca1d4826c (patch) | |
tree | b31aa6df6f31fc259af8810dcddfb09c275d5cb8 /400.mu | |
parent | 2d3fe4e940deb0078bef80f0f56ea38852c991e7 (diff) | |
download | mu-ef73cb78f15839cf0254ead273e0d1eca1d4826c.tar.gz |
initial image rendering
Supports just some ASCII formats: https://en.wikipedia.org/wiki/Netpbm Colors are messed up. That's next.
Diffstat (limited to '400.mu')
-rw-r--r-- | 400.mu | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/400.mu b/400.mu index e6cb48c2..0f0ccd00 100644 --- a/400.mu +++ b/400.mu @@ -98,6 +98,10 @@ sig to-decimal-digit in: grapheme -> _/eax: int # next-raw-word really reads whitespace-separated words sig next-word line: (addr stream byte), out: (addr slice) # skips '#' comments sig next-raw-word line: (addr stream byte), out: (addr slice) # does not skip '#' comments +sig skip-chars-matching in: (addr stream byte), delimiter: byte +sig skip-chars-matching-whitespace in: (addr stream byte) +sig skip-chars-not-matching in: (addr stream byte), delimiter: byte +sig skip-chars-not-matching-whitespace in: (addr stream byte) sig stream-empty? s: (addr stream _) -> _/eax: boolean sig stream-full? s: (addr stream _) -> _/eax: boolean sig stream-to-array in: (addr stream _), out: (addr handle array _) |