summaryrefslogtreecommitdiff
path: root/2025/ocaml/lib/infrastructure/file.ml
diff options
context:
space:
mode:
Diffstat (limited to '2025/ocaml/lib/infrastructure/file.ml')
-rw-r--r--2025/ocaml/lib/infrastructure/file.ml4
1 files changed, 4 insertions, 0 deletions
diff --git a/2025/ocaml/lib/infrastructure/file.ml b/2025/ocaml/lib/infrastructure/file.ml
new file mode 100644
index 0000000..3b49c01
--- /dev/null
+++ b/2025/ocaml/lib/infrastructure/file.ml
@@ -0,0 +1,4 @@
+let read filename =
+ let chan = In_channel.open_text filename in
+ let content = In_channel.input_all chan in
+ In_channel.close chan ; content