aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib/src
diff options
context:
space:
mode:
authorHans Bolinder <[email protected]>2017-02-28 14:35:18 +0100
committerHans Bolinder <[email protected]>2017-02-28 14:35:18 +0100
commitc1ea854fac3d8ed144c7fcc909a4671331e43c16 (patch)
treeeeaca3d8b235047096abb7cdc1eb2d84dfa8c92a /lib/stdlib/src
parent883f7e91005a5527c7b199bac8d642518a502061 (diff)
parent52f822ab407be031a0013f47ff2b1b45b27fc1f5 (diff)
downloadotp-c1ea854fac3d8ed144c7fcc909a4671331e43c16.tar.gz
otp-c1ea854fac3d8ed144c7fcc909a4671331e43c16.tar.bz2
otp-c1ea854fac3d8ed144c7fcc909a4671331e43c16.zip
Merge branch 'maint'
* maint: stdlib: Add maps to term traversal
Diffstat (limited to 'lib/stdlib/src')
-rw-r--r--lib/stdlib/src/qlc.erl6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/stdlib/src/qlc.erl b/lib/stdlib/src/qlc.erl
index f3665824f2..8c4d835432 100644
--- a/lib/stdlib/src/qlc.erl
+++ b/lib/stdlib/src/qlc.erl
@@ -1,7 +1,7 @@
%%
%% %CopyrightBegin%
%%
-%% Copyright Ericsson AB 2004-2016. All Rights Reserved.
+%% Copyright Ericsson AB 2004-2017. All Rights Reserved.
%%
%% Licensed under the Apache License, Version 2.0 (the "License");
%% you may not use this file except in compliance with the License.
@@ -1292,6 +1292,10 @@ abstr_term(Fun, Line) when is_function(Fun) ->
end;
abstr_term(PPR, Line) when is_pid(PPR); is_port(PPR); is_reference(PPR) ->
{special, Line, lists:flatten(io_lib:write(PPR))};
+abstr_term(Map, Line) when is_map(Map) ->
+ {map,Line,
+ [{map_field_assoc,Line,abstr_term(K, Line),abstr_term(V, Line)} ||
+ {K,V} <- maps:to_list(Map)]};
abstr_term(Simple, Line) ->
erl_parse:abstract(Simple, erl_anno:line(Line)).