From 467c4e5d198e0c4b9262c8e150a572050071ad41 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Gustavsson?= Date: Thu, 12 May 2016 15:53:36 +0200 Subject: core_pp: Remove uncovered clause in is_simple_term/1 The clause for handling #c_values{} in is_simple_term/1 is never executed. It can be safely removed, since there is a default clause that will return 'false' in the extremly unlikely event that a Without the clause, code such as: let <_v1,_v2> = <1,2> in {_v1,_v2} would be printed with an extra newline: let <_v1,_v2> = <1,2> in {_v1,_v2} --- lib/compiler/src/core_pp.erl | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/compiler/src/core_pp.erl b/lib/compiler/src/core_pp.erl index 22171a70c7..67209d06be 100644 --- a/lib/compiler/src/core_pp.erl +++ b/lib/compiler/src/core_pp.erl @@ -518,8 +518,6 @@ add_indent(Ctxt, Dx) -> core_atom(A) -> io_lib:write_string(atom_to_list(A), $'). -is_simple_term(#c_values{es=Es}) -> - length(Es) < 3 andalso lists:all(fun is_simple_term/1, Es); is_simple_term(#c_tuple{es=Es}) -> length(Es) < 4 andalso lists:all(fun is_simple_term/1, Es); is_simple_term(#c_var{}) -> true; -- cgit v1.2.3