Browse thread
[Caml-list] Evaluation Order
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | John Max Skaller <skaller@o...> |
| Subject: | Re: [Caml-list] Evaluation Order |
Tore Lund wrote: > # let _ = > print_string "before"; > print_string "MIDDLE"; > print_string "after";; > beforeMIDDLEafter- : unit = () > > but not in this one: > > # let _ = > print_string "before"; > Format.print_string "MIDDLE"; > print_string "after";; > beforeafterMIDDLE- : unit = () > > What's going on here? Buffering I guess. print_string buffers using stdio buffers. Format.* has its own buffer, which is flushed into the stdout buffer too late. -- John (Max) Skaller, mailto:skaller@maxtal.com.au 10/1 Toxteth Rd Glebe NSW 2037 Australia voice: 61-2-9660-0850 checkout Vyper http://Vyper.sourceforge.net download Interscript http://Interscript.sourceforge.net ------------------- Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr