aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib/test
diff options
context:
space:
mode:
authorZandra <[email protected]>2015-12-28 12:08:32 +0100
committerZandra <[email protected]>2015-12-28 12:08:32 +0100
commit7be5ba1d5aa0809021c69e26ddbecf29e65c1fce (patch)
tree343d12f9bc0dc0cd73ffbbc3338d4591d1b67db0 /lib/stdlib/test
parent7dc1b19582a61281742fd1dcc880899b72e6becb (diff)
parent4f2d5c08a08e25e9b5b1b2011a8efe2fea441049 (diff)
downloadotp-7be5ba1d5aa0809021c69e26ddbecf29e65c1fce.tar.gz
otp-7be5ba1d5aa0809021c69e26ddbecf29e65c1fce.tar.bz2
otp-7be5ba1d5aa0809021c69e26ddbecf29e65c1fce.zip
Merge branch 'maint'
Diffstat (limited to 'lib/stdlib/test')
-rw-r--r--lib/stdlib/test/erl_eval_SUITE.erl10
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/stdlib/test/erl_eval_SUITE.erl b/lib/stdlib/test/erl_eval_SUITE.erl
index b9c4ad0a46..50fc62a00e 100644
--- a/lib/stdlib/test/erl_eval_SUITE.erl
+++ b/lib/stdlib/test/erl_eval_SUITE.erl
@@ -1483,6 +1483,16 @@ eep43(Config) when is_list(Config) ->
" #{ K1 := 1, K2 := 2, K3 := 3, {2,2} := 4} = Map "
"end.",
#{ 1 => 1, <<42:301>> => 2, {3,<<42:301>>} => 3, {2,2} => 4}),
+ check(fun () ->
+ X = key,
+ (fun(#{X := value}) -> true end)(#{X => value})
+ end,
+ "begin "
+ " X = key, "
+ " (fun(#{X := value}) -> true end)(#{X => value}) "
+ "end.",
+ true),
+
error_check("[camembert]#{}.", {badmap,[camembert]}),
error_check("[camembert]#{nonexisting:=v}.", {badmap,[camembert]}),
error_check("#{} = 1.", {badmatch,1}),