From 116e8aa05f84ee66aead2792b07b644c7f3e8fcd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Gustavsson?= Date: Tue, 3 Feb 2015 10:00:13 +0100 Subject: cerl: Teach is_literal_term/1 to handle maps --- lib/compiler/src/cerl.erl | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib/compiler/src/cerl.erl') diff --git a/lib/compiler/src/cerl.erl b/lib/compiler/src/cerl.erl index 5d6997da11..3d4b9ee0c6 100644 --- a/lib/compiler/src/cerl.erl +++ b/lib/compiler/src/cerl.erl @@ -434,6 +434,8 @@ is_literal_term([H | T]) -> is_literal_term(T) when is_tuple(T) -> is_literal_term_list(tuple_to_list(T)); is_literal_term(B) when is_bitstring(B) -> true; +is_literal_term(M) when is_map(M) -> + is_literal_term_list(maps:to_list(M)); is_literal_term(_) -> false. -- cgit v1.2.3