aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib/src
diff options
context:
space:
mode:
authorIgor Savchuk <[email protected]>2014-07-10 11:42:24 +0400
committerIgor Savchuk <[email protected]>2014-07-10 11:42:24 +0400
commit09ed7cb41a89b56db84dd5e0b15b2fa27d198e71 (patch)
tree5f5a591338db89b658a436e6a8b7181240084e96 /lib/stdlib/src
parent0cf5e4d5195b717590ac938df796c69399a4ca07 (diff)
downloadotp-09ed7cb41a89b56db84dd5e0b15b2fa27d198e71.tar.gz
otp-09ed7cb41a89b56db84dd5e0b15b2fa27d198e71.tar.bz2
otp-09ed7cb41a89b56db84dd5e0b15b2fa27d198e71.zip
maps:only/2 -> maps:with/2
Diffstat (limited to 'lib/stdlib/src')
-rw-r--r--lib/stdlib/src/maps.erl6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/stdlib/src/maps.erl b/lib/stdlib/src/maps.erl
index b8b284db65..e72e590834 100644
--- a/lib/stdlib/src/maps.erl
+++ b/lib/stdlib/src/maps.erl
@@ -24,7 +24,7 @@
map/2,
size/1,
without/2,
- only/2,
+ with/2,
get/3
]).
@@ -204,11 +204,11 @@ without(Ks, M) when is_list(Ks), is_map(M) ->
maps:from_list([{K,V}||{K,V} <- maps:to_list(M), not lists:member(K, Ks)]).
--spec only(Ks, Map1) -> Map2 when
+-spec with(Ks, Map1) -> Map2 when
Ks :: [K],
Map1 :: map(),
Map2 :: map(),
K :: term().
-only(Ks, M) when is_list(Ks), is_map(M) ->
+with(Ks, M) when is_list(Ks), is_map(M) ->
maps:from_list([{K,V}||{K,V} <- maps:to_list(M), lists:member(K, Ks)]).