aboutsummaryrefslogtreecommitdiffstats
path: root/lib/dialyzer/src/dialyzer_analysis_callgraph.erl
diff options
context:
space:
mode:
authorLuca Favatella <[email protected]>2015-10-16 00:31:11 +0100
committerLuca Favatella <[email protected]>2015-10-27 22:17:53 +0000
commit33ddd3f0699cbb4aa9aea2ec7fcf690d5c498c53 (patch)
treef1467326cbb4e3c616a04aba5ddac6f3f40617a3 /lib/dialyzer/src/dialyzer_analysis_callgraph.erl
parent7dc9eefa341fbfae0ebc55a88b96a375c611e3a4 (diff)
downloadotp-33ddd3f0699cbb4aa9aea2ec7fcf690d5c498c53.tar.gz
otp-33ddd3f0699cbb4aa9aea2ec7fcf690d5c498c53.tar.bz2
otp-33ddd3f0699cbb4aa9aea2ec7fcf690d5c498c53.zip
Teach Dialyzer call to funs `M:F/A` (literal M, F, A)
Diffstat (limited to 'lib/dialyzer/src/dialyzer_analysis_callgraph.erl')
-rw-r--r--lib/dialyzer/src/dialyzer_analysis_callgraph.erl22
1 files changed, 22 insertions, 0 deletions
diff --git a/lib/dialyzer/src/dialyzer_analysis_callgraph.erl b/lib/dialyzer/src/dialyzer_analysis_callgraph.erl
index c57a22129c..826ac51775 100644
--- a/lib/dialyzer/src/dialyzer_analysis_callgraph.erl
+++ b/lib/dialyzer/src/dialyzer_analysis_callgraph.erl
@@ -624,6 +624,28 @@ find_call_file_and_line(Tree, MFA) ->
MFA ->
Ann = cerl:get_ann(SubTree),
[{get_file(Ann), get_line(Ann)}|Acc];
+ {erlang, make_fun, 3} ->
+ [CA1, CA2, CA3] = cerl:call_args(SubTree),
+ case
+ cerl:is_c_atom(CA1) andalso
+ cerl:is_c_atom(CA2) andalso
+ cerl:is_c_int(CA3)
+ of
+ true ->
+ case
+ {cerl:concrete(CA1),
+ cerl:concrete(CA2),
+ cerl:concrete(CA3)}
+ of
+ MFA ->
+ Ann = cerl:get_ann(SubTree),
+ [{get_file(Ann), get_line(Ann)}|Acc];
+ _ ->
+ Acc
+ end;
+ false ->
+ Acc
+ end;
_ -> Acc
end;
false -> Acc