Skip to content

Commit 81cc65f

Browse files
authored
Merge pull request diffblue#1599 from NathanJPhillips/move-show-symbol-table-from-module-pass
Fix location of show-symbol-table
2 parents 0da026b + 1a7dfdf commit 81cc65f

File tree

2 files changed

+29
-28
lines changed

2 files changed

+29
-28
lines changed

src/clobber/clobber_parse_options.cpp

+15-14
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,21 @@ int clobber_parse_optionst::doit()
126126
{
127127
goto_model=initialize_goto_model(cmdline, get_message_handler());
128128

129+
130+
// show it?
131+
if(cmdline.isset("show-loops"))
132+
{
133+
show_loop_ids(get_ui(), goto_model);
134+
return 6;
135+
}
136+
137+
// show it?
138+
if(cmdline.isset("show-goto-functions"))
139+
{
140+
show_goto_functions(goto_model, get_ui());
141+
return 6;
142+
}
143+
129144
label_properties(goto_model);
130145

131146
if(cmdline.isset("show-properties"))
@@ -211,20 +226,6 @@ bool clobber_parse_optionst::process_goto_program(
211226

212227
if(cmdline.isset("cover-assertions"))
213228
make_assertions_false(goto_model);
214-
215-
// show it?
216-
if(cmdline.isset("show-loops"))
217-
{
218-
show_loop_ids(get_ui(), goto_model);
219-
return true;
220-
}
221-
222-
// show it?
223-
if(cmdline.isset("show-goto-functions"))
224-
{
225-
show_goto_functions(goto_model, get_ui());
226-
return true;
227-
}
228229
}
229230

230231
return false;

src/goto-analyzer/goto_analyzer_parse_options.cpp

+14-14
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,20 @@ int goto_analyzer_parse_optionst::doit()
185185
if(process_goto_program(options))
186186
return 6;
187187

188+
// show it?
189+
if(cmdline.isset("show-symbol-table"))
190+
{
191+
::show_symbol_table(goto_model.symbol_table, get_ui());
192+
return 6;
193+
}
194+
195+
// show it?
196+
if(cmdline.isset("show-goto-functions"))
197+
{
198+
show_goto_functions(goto_model, get_ui());
199+
return 6;
200+
}
201+
188202
if(cmdline.isset("taint"))
189203
{
190204
std::string taint_file=cmdline.get_value("taint");
@@ -400,20 +414,6 @@ bool goto_analyzer_parse_optionst::process_goto_program(
400414

401415
// add loop ids
402416
goto_model.goto_functions.compute_loop_numbers();
403-
404-
// show it?
405-
if(cmdline.isset("show-goto-functions"))
406-
{
407-
show_goto_functions(goto_model, get_ui());
408-
return true;
409-
}
410-
411-
// show it?
412-
if(cmdline.isset("show-symbol-table"))
413-
{
414-
::show_symbol_table(goto_model, get_ui());
415-
return true;
416-
}
417417
}
418418

419419
catch(const char *e)

0 commit comments

Comments
 (0)