diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/gleam/io.gleam | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/gleam/io.gleam b/src/gleam/io.gleam new file mode 100644 index 0000000..b7f1691 --- /dev/null +++ b/src/gleam/io.gleam @@ -0,0 +1,17 @@ +external type DoNotLeak + +external fn erl_print(String) -> DoNotLeak = + "io" "fwrite" + +/// Writes string to standard output +/// +/// ## Example +/// +/// > io.print("Hi mum") +/// Nil +/// //=> Hi mum +/// +pub fn print(string: String) -> Nil { + erl_print(string) + Nil +}
\ No newline at end of file |