aboutsummaryrefslogtreecommitdiffstats
path: root/lib/dialyzer/src/dialyzer_analysis_callgraph.erl
diff options
context:
space:
mode:
authorHenrik Nord <[email protected]>2014-09-09 14:15:02 +0200
committerHenrik Nord <[email protected]>2014-09-09 14:15:05 +0200
commitf551de9de308ae5f21adc0e59806eab39146da7d (patch)
tree257dc7950c41697368760f947f3918273368f8f8 /lib/dialyzer/src/dialyzer_analysis_callgraph.erl
parenta146b28e6b17dbd2cae9ef090e5950985ec9dfe9 (diff)
parent80095fe4ee85f7374757472897581b9943363417 (diff)
downloadotp-f551de9de308ae5f21adc0e59806eab39146da7d.tar.gz
otp-f551de9de308ae5f21adc0e59806eab39146da7d.tar.bz2
otp-f551de9de308ae5f21adc0e59806eab39146da7d.zip
Merge branch 'fishcakez/dialyzer_beam_opts' into maint
* fishcakez/dialyzer_beam_opts: Use compile options when dialyzing beam files
Diffstat (limited to 'lib/dialyzer/src/dialyzer_analysis_callgraph.erl')
-rw-r--r--lib/dialyzer/src/dialyzer_analysis_callgraph.erl11
1 files changed, 10 insertions, 1 deletions
diff --git a/lib/dialyzer/src/dialyzer_analysis_callgraph.erl b/lib/dialyzer/src/dialyzer_analysis_callgraph.erl
index 6a33a2acb3..af1c2b7e3a 100644
--- a/lib/dialyzer/src/dialyzer_analysis_callgraph.erl
+++ b/lib/dialyzer/src/dialyzer_analysis_callgraph.erl
@@ -373,7 +373,16 @@ compile_byte(File, Callgraph, CServer, UseContracts) ->
{error, " Could not get abstract code for: " ++ File ++ "\n" ++
" Recompile with +debug_info or analyze starting from source code"};
{ok, AbstrCode} ->
- compile_common(File, AbstrCode, [], Callgraph, CServer, UseContracts)
+ compile_byte(File, AbstrCode, Callgraph, CServer, UseContracts)
+ end.
+
+compile_byte(File, AbstrCode, Callgraph, CServer, UseContracts) ->
+ case dialyzer_utils:get_compile_options_from_beam(File) of
+ error ->
+ {error, " Could not get compile options for: " ++ File ++ "\n" ++
+ " Recompile or analyze starting from source code"};
+ {ok, CompOpts} ->
+ compile_common(File, AbstrCode, CompOpts, Callgraph, CServer, UseContracts)
end.
compile_common(File, AbstrCode, CompOpts, Callgraph, CServer, UseContracts) ->