aboutsummaryrefslogtreecommitdiff
path: root/src/gleam__stdlib.erl
diff options
context:
space:
mode:
authorLouis Pilfold <louis@lpil.uk>2019-03-12 18:30:12 +0000
committerLouis Pilfold <louis@lpil.uk>2019-03-12 18:32:51 +0000
commit80a8083b143eaa24218ec5fda16f947658fb823d (patch)
tree32b64f2327e30270e0f2126ee0f80363956d4527 /src/gleam__stdlib.erl
parent2a7d9061e4ec9c763053b078db2d98400bd08dd5 (diff)
downloadgleam_stdlib-80a8083b143eaa24218ec5fda16f947658fb823d.tar.gz
gleam_stdlib-80a8083b143eaa24218ec5fda16f947658fb823d.zip
Compile map module
Diffstat (limited to 'src/gleam__stdlib.erl')
-rw-r--r--src/gleam__stdlib.erl11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/gleam__stdlib.erl b/src/gleam__stdlib.erl
index e4b76f7..4af95eb 100644
--- a/src/gleam__stdlib.erl
+++ b/src/gleam__stdlib.erl
@@ -1,7 +1,10 @@
-module(gleam__stdlib).
--compile(export_all).
-include_lib("eunit/include/eunit.hrl").
+-export([expect_equal/2, expect_not_equal/2, expect_true/1, expect_false/1, map_fetch/2,
+ iodata_append/2, iodata_prepend/2, identity/1]).
+
+
expect_equal(A, Expected) -> ?assertEqual(Expected, A).
expect_not_equal(A, Expected) -> ?assertNotEqual(Expected, A).
expect_true(A) -> ?assert(A).
@@ -9,11 +12,11 @@ expect_false(A) -> ?assertNot(A).
map_fetch(Map, Key) ->
case maps:find(Key, Map) of
- error -> {error, {}},
+ error -> {error, {}};
OkFound -> OkFound
end.
-iodata_append(X, Data) -> [X | Y].
-iodata_prepend(X, Data) -> [Y, X].
+iodata_append(Iodata, String) -> [Iodata, String].
+iodata_prepend(Iodata, String) -> [String, Iodata].
identity(X) -> X.