about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2016-08-18 20:44:56 -0700
committerKartik K. Agaram <vc@akkartik.com>2016-08-18 20:46:10 -0700
commit47219d0b2b41096547a02b506d7413fe9a3d308a (patch)
tree060efeeec60ae609951f1ae00fc26ba916c3df10
parent4588af9793a486a46fe04d1d67ab083b242db1a7 (diff)
downloadmu-47219d0b2b41096547a02b506d7413fe9a3d308a.tar.gz
3224
-rw-r--r--088file.mu5
-rw-r--r--filesystem.mu6
2 files changed, 3 insertions, 8 deletions
diff --git a/088file.mu b/088file.mu
index 25263fa9..6e6a89e1 100644
--- a/088file.mu
+++ b/088file.mu
@@ -10,9 +10,6 @@ def start-reading fs:address:filesystem, filename:address:array:character -> con
   load-ingredients
   x:number/file <- $open-file-for-reading filename
   contents:address:source:character, sink:address:sink:character <- new-channel 30
-  $print [sink: ], sink, 10/newline
-  chan:address:channel:character <- get *sink, chan:offset
-  $print [chan in start-reading: ], chan, 10/newline
   start-running transmit x, sink
 ]
 
@@ -25,7 +22,5 @@ def transmit file:number, sink:address:sink:character -> file:number, sink:addre
     sink <- write sink, c
     loop
   }
-  $print [closing chan after reading file], 10/newline
   sink <- close sink
-  $print [returning from 'transmit'], 10/newline
 ]
diff --git a/filesystem.mu b/filesystem.mu
index 7aa919e6..274397be 100644
--- a/filesystem.mu
+++ b/filesystem.mu
@@ -1,6 +1,6 @@
 def main [
   local-scope
-  $print [file to read from: ], [/tmp/mu-fs]
+  $print [reading characters from /tmp/mu-fs], 10/newline
   # initialize filesystem
   fs:address:filesystem <- copy 0/real-filesystem
   content-source:address:source:character <- start-reading fs, [/tmp/mu-fs]
@@ -8,9 +8,9 @@ def main [
   {
     c:character, done?:boolean, content-source <- read content-source
     break-if done?
-    $print [Next: ], c, 10/newline
+    $print [  ], c, 10/newline
     loop
   }
-  $print [Done reading], 10/newline
+  $print [done reading], 10/newline
   # TODO: writing to file
 ]