diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2021-07-03 18:27:01 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2021-07-03 18:27:01 -0700 |
commit | c95648c96093ce0d44c21191bab0ee2c9b04becc (patch) | |
tree | eb58e435a158100b99e152199b193acc53df4ab3 /400.mu | |
parent | 7ced4e44ddb6e15152eb8bcef9dda68aba53710b (diff) | |
download | mu-c95648c96093ce0d44c21191bab0ee2c9b04becc.tar.gz |
reading from streams
The Mu shell has no string literals, only streams. No random access, only sequential access. But I've been playing fast and loose with its read pointer until now. Hopefully things are cleaned up now.
Diffstat (limited to '400.mu')
-rw-r--r-- | 400.mu | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/400.mu b/400.mu index ab1c6dc0..e6cb48c2 100644 --- a/400.mu +++ b/400.mu @@ -57,6 +57,7 @@ sig try-write f: (addr stream byte), s: (addr array byte) -> _/eax: boolean sig stream-size f: (addr stream byte) -> _/eax: int sig space-remaining-in-stream f: (addr stream byte) -> _/eax: int sig write-stream f: (addr stream byte), s: (addr stream byte) +sig write-stream-immutable f: (addr stream byte), s: (addr stream byte) sig read-byte s: (addr stream byte) -> _/eax: byte sig append-byte f: (addr stream byte), n: int # really just a byte, but I want to pass in literal numbers #sig to-hex-char in/eax: int -> out/eax: int |