blob: 49641a6d83e587946273322c9d2f89b3e8a6c77d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
-module(gleam@int).
-compile(no_auto_import).
-export([parse/1, to_string/1, to_base_string/2, compare/2]).
parse(A) ->
gleam__stdlib:parse_int(A).
to_string(A) ->
erlang:integer_to_binary(A).
to_base_string(A, B) ->
erlang:integer_to_binary(A, B).
compare(A, B) ->
case A =:= B of
true ->
eq;
false ->
case A < B of
true ->
lt;
false ->
gt
end
end.
|