Skip to content

Commit 4edecbc

Browse files
committed
Rename add_cprover_X_library to cprover_X_library_factory
This name more clearly describes what these functions do.
1 parent 1201ffe commit 4edecbc

8 files changed

+17
-12
lines changed

src/ansi-c/cprover_library.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ std::string get_cprover_library_text(
7474
return library_text.str();
7575
}
7676

77-
void add_cprover_c_library(
77+
void cprover_c_library_factory(
7878
const std::set<irep_idt> &functions,
7979
symbol_tablet &symbol_table,
8080
message_handlert &message_handler)

src/ansi-c/cprover_library.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ void add_library(
3232
symbol_tablet &,
3333
message_handlert &);
3434

35-
void add_cprover_c_library(
35+
void cprover_c_library_factory(
3636
const std::set<irep_idt> &functions,
3737
symbol_tablet &,
3838
message_handlert &);

src/cbmc/cbmc_parse_options.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -717,9 +717,9 @@ bool cbmc_parse_optionst::process_goto_program(
717717
log.status() << "Adding CPROVER library (" << config.ansi_c.arch << ")"
718718
<< eom;
719719
link_to_library(
720-
goto_model, log.get_message_handler(), add_cprover_cpp_library);
720+
goto_model, log.get_message_handler(), cprover_cpp_library_factory);
721721
link_to_library(
722-
goto_model, log.get_message_handler(), add_cprover_c_library);
722+
goto_model, log.get_message_handler(), cprover_c_library_factory);
723723

724724
if(options.get_bool_option("string-abstraction"))
725725
string_instrumentation(goto_model, log.get_message_handler());

src/cpp/cprover_library.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ static std::string get_cprover_library_text(
3535
functions, symbol_table, cprover_library, library_text.str());
3636
}
3737

38-
void add_cprover_cpp_library(
38+
void cprover_cpp_library_factory(
3939
const std::set<irep_idt> &functions,
4040
symbol_tablet &symbol_table,
4141
message_handlert &message_handler)

src/cpp/cprover_library.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Author: Michael Tautschnig
1616
class message_handlert;
1717
class symbol_tablet;
1818

19-
void add_cprover_cpp_library(
19+
void cprover_cpp_library_factory(
2020
const std::set<irep_idt> &functions,
2121
symbol_tablet &,
2222
message_handlert &);

src/goto-analyzer/goto_analyzer_parse_options.cpp

+3-2
Original file line numberDiff line numberDiff line change
@@ -729,8 +729,9 @@ bool goto_analyzer_parse_optionst::process_goto_program(
729729

730730
// add the library
731731
status() << "Adding CPROVER library (" << config.ansi_c.arch << ")" << eom;
732-
link_to_library(goto_model, ui_message_handler, add_cprover_cpp_library);
733-
link_to_library(goto_model, ui_message_handler, add_cprover_c_library);
732+
link_to_library(
733+
goto_model, ui_message_handler, cprover_cpp_library_factory);
734+
link_to_library(goto_model, ui_message_handler, cprover_c_library_factory);
734735
#endif
735736

736737
// remove function pointers

src/goto-diff/goto_diff_parse_options.cpp

+4-2
Original file line numberDiff line numberDiff line change
@@ -398,8 +398,10 @@ bool goto_diff_parse_optionst::process_goto_program(
398398

399399
// add the library
400400
status() << "Adding CPROVER library (" << config.ansi_c.arch << ")" << eom;
401-
link_to_library(goto_model, get_message_handler(), add_cprover_cpp_library);
402-
link_to_library(goto_model, get_message_handler(), add_cprover_c_library);
401+
link_to_library(
402+
goto_model, get_message_handler(), cprover_cpp_library_factory);
403+
link_to_library(
404+
goto_model, get_message_handler(), cprover_c_library_factory);
403405

404406
// remove function pointers
405407
status() << "Removal of function pointers and virtual functions" << eom;

src/goto-instrument/goto_instrument_parse_options.cpp

+4-2
Original file line numberDiff line numberDiff line change
@@ -961,8 +961,10 @@ void goto_instrument_parse_optionst::instrument_goto_program()
961961

962962
// add the library
963963
status() << "Adding CPROVER library (" << config.ansi_c.arch << ")" << eom;
964-
link_to_library(goto_model, get_message_handler(), add_cprover_cpp_library);
965-
link_to_library(goto_model, get_message_handler(), add_cprover_c_library);
964+
link_to_library(
965+
goto_model, get_message_handler(), cprover_cpp_library_factory);
966+
link_to_library(
967+
goto_model, get_message_handler(), cprover_c_library_factory);
966968
}
967969

968970
// now do full inlining, if requested

0 commit comments

Comments
 (0)