blob: 7aa919e6a615e2b686656f68387c2c9afcdc1785 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
def main [
local-scope
$print [file to read from: ], [/tmp/mu-fs]
# initialize filesystem
fs:address:filesystem <- copy 0/real-filesystem
content-source:address:source:character <- start-reading fs, [/tmp/mu-fs]
# read from channel until exhausted and print out characters
{
c:character, done?:boolean, content-source <- read content-source
break-if done?
$print [Next: ], c, 10/newline
loop
}
$print [Done reading], 10/newline
# TODO: writing to file
]
|