aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib/src
diff options
context:
space:
mode:
authorHans Bolinder <[email protected]>2017-02-24 13:13:16 +0100
committerHans Bolinder <[email protected]>2017-02-27 09:40:24 +0100
commit1870c04e56f56334fc836c1f64c5e123dc9a359b (patch)
tree2e913eb21cc49496aa2465a108b80670528b0f95 /lib/stdlib/src
parent133645d9a24e6a6d7123370ef332ca478598040e (diff)
downloadotp-1870c04e56f56334fc836c1f64c5e123dc9a359b.tar.gz
otp-1870c04e56f56334fc836c1f64c5e123dc9a359b.tar.bz2
otp-1870c04e56f56334fc836c1f64c5e123dc9a359b.zip
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)).