aboutsummaryrefslogtreecommitdiffstats
path: root/lib/dialyzer/src/dialyzer_gui_wx.erl
diff options
context:
space:
mode:
authorBjörn-Egil Dahlberg <[email protected]>2010-12-02 12:24:18 +0100
committerBjörn-Egil Dahlberg <[email protected]>2010-12-02 12:24:26 +0100
commit4c24c029fbd5263e3dc0ce0d4a23574a05c9bbc3 (patch)
tree7bef76c162b15eb26447236f1fc323fe3b0a39dc /lib/dialyzer/src/dialyzer_gui_wx.erl
parent13338198802371d70ca40686d2998861b45edcc4 (diff)
parentf1d81c87d832c805a90a8dceca247cecaad803ab (diff)
downloadotp-4c24c029fbd5263e3dc0ce0d4a23574a05c9bbc3.tar.gz
otp-4c24c029fbd5263e3dc0ce0d4a23574a05c9bbc3.tar.bz2
otp-4c24c029fbd5263e3dc0ce0d4a23574a05c9bbc3.zip
Merge branch 'ks/dialyzer/support-multiple-plts' into dev
* ks/dialyzer/support-multiple-plts: dialyzer: Add support for multiple PLTs OTP-8962
Diffstat (limited to 'lib/dialyzer/src/dialyzer_gui_wx.erl')
-rw-r--r--lib/dialyzer/src/dialyzer_gui_wx.erl14
1 files changed, 9 insertions, 5 deletions
diff --git a/lib/dialyzer/src/dialyzer_gui_wx.erl b/lib/dialyzer/src/dialyzer_gui_wx.erl
index 2e309d7ec1..e711c15ea7 100644
--- a/lib/dialyzer/src/dialyzer_gui_wx.erl
+++ b/lib/dialyzer/src/dialyzer_gui_wx.erl
@@ -88,7 +88,7 @@ start(DialyzerOptions) ->
State = wx:batch(fun() -> create_window(Wx, DialyzerOptions) end),
gui_loop(State).
-create_window(Wx, DialyzerOptions) ->
+create_window(Wx, #options{init_plts = InitPltFiles} = DialyzerOptions) ->
{ok, Host} = inet:gethostname(),
%%---------- initializing frame ---------
@@ -258,11 +258,15 @@ create_window(Wx, DialyzerOptions) ->
plt = PltMenu,
options =OptionsMenu,
help = HelpMenu},
-
- InitPlt = try dialyzer_plt:from_file(DialyzerOptions#options.init_plt)
- catch throw:{dialyzer_error, _} -> dialyzer_plt:new()
- end,
+ InitPlt =
+ case InitPltFiles of
+ [] -> dialyzer_plt:new();
+ _ ->
+ Plts = [dialyzer_plt:from_file(F) || F <- InitPltFiles],
+ dialyzer_plt:merge_plts_or_report_conflicts(InitPltFiles, Plts)
+ end,
+
#gui_state{add = AddButton,
add_dir = AddDirButton,
add_rec = AddRecButton,