RosettaCodeData/Task/Read-entire-file/Standard-ML/read-entire-file.ml
2024-04-19 16:56:29 -07:00

4 lines
131 B
Standard ML

(* string -> string *)
fun readFile path =
(fn strm =>
TextIO.inputAll strm before TextIO.closeIn strm) (TextIO.openIn path)