dump-c: Replace --use-system-headers by --no-system-headers

The user-friendly default now is to produce #include statements for C library
functions; this can be disabled using --no-system-headers.
This commit is contained in:
Michael Tautschnig 2017-07-03 14:29:32 +01:00
parent e2cfed345c
commit 34a476fa33
4 changed files with 6 additions and 5 deletions

View File

@ -8,7 +8,8 @@
* GOTO-ANALYZER: New option --unreachable-functions, --reachable-functions
* GOTO-INSTRUMENT: New option --undefined-function-is-assume-false
* GOTO-INSTRUMENT: New option --remove-function-body
* GOTO-INSTRUMENT: New option --use-all-headers
* GOTO-INSTRUMENT: New option --use-all-headers, changed --use-system-headers to
--no-system-headers
5.7

View File

@ -1,6 +1,6 @@
CORE
main.c
--dump-c --use-system-headers
--dump-c
^EXIT=0$
^SIGNAL=0$
--

View File

@ -621,7 +621,7 @@ int goto_instrument_parse_optionst::doit()
if(cmdline.isset("dump-c") || cmdline.isset("dump-cpp"))
{
const bool is_cpp=cmdline.isset("dump-cpp");
const bool h_libc=cmdline.isset("use-system-headers");
const bool h_libc=!cmdline.isset("no-system-headers");
const bool h_all=cmdline.isset("use-all-headers");
namespacet ns(symbol_table);
@ -1542,7 +1542,7 @@ void goto_instrument_parse_optionst::help()
" --remove-function-body <f> remove the implementation of function <f> (may be repeated)\n"
"\n"
"Other options:\n"
" --use-system-headers with --dump-c/--dump-cpp: generate C source with libc includes\n" // NOLINT(*)
" --no-system-headers with --dump-c/--dump-cpp: generate C source expanding libc includes\n" // NOLINT(*)
" --use-all-headers with --dump-c/--dump-cpp: generate C source with all includes\n" // NOLINT(*)
" --version show version and exit\n"
" --xml-ui use XML-formatted output\n"

View File

@ -26,7 +26,7 @@ Author: Daniel Kroening, kroening@kroening.com
"(all)" \
"(document-claims-latex)(document-claims-html)" \
"(document-properties-latex)(document-properties-html)" \
"(dump-c)(dump-cpp)(use-system-headers)(use-all-headers)(dot)(xml)" \
"(dump-c)(dump-cpp)(no-system-headers)(use-all-headers)(dot)(xml)" \
OPT_GOTO_CHECK \
/* no-X-check are deprecated and ignored */ \
"(no-bounds-check)(no-pointer-check)(no-div-by-zero-check)" \