diff options
Diffstat (limited to 'gen/src/float.erl')
-rw-r--r-- | gen/src/float.erl | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gen/src/float.erl b/gen/src/float.erl index f9e4064..cd1385c 100644 --- a/gen/src/float.erl +++ b/gen/src/float.erl @@ -1,7 +1,7 @@ -module(float). -compile(no_auto_import). --export([parse/1, to_string/1, ceiling/1, floor/1, round/1]). +-export([parse/1, to_string/1, ceiling/1, floor/1, round/1, truncate/1]). parse(A) -> gleam__stdlib:parse_float(A). @@ -17,3 +17,6 @@ floor(A) -> round(A) -> erlang:round(A). + +truncate(A) -> + erlang:trunc(A). |