Skip to content
Snippets Groups Projects
Commit e1b503d7 authored by Jakub Jelinek's avatar Jakub Jelinek
Browse files

c++: Fix up -fcontract* options

I've noticed
+FAIL: compiler driver --help=c++ option(s): "^ +-.*[^:.]\$" absent from output: "  -fcontract-build-level=[off|default|audit] Specify max contract level to generate runtime checks for"
error, this is due to missing dot at the end of the description.

The second part of the first hunk should fix that, but while at it,
I find it weird that some options don't have RejectNegative, yet
for options that accept an argument a negative option looks weird
and isn't really handled.

Though, shall we have those [on|off] options at all?
Those are inconsistent with all other boolean options gcc has.
Every other boolean option is -fwhatever for it being on
and -fno-whatever for it being off, shouldn't the options be
without arguments and accept negatives (-fcontract-assumption-mode
vs. -fno-contract-assumption-mode etc.)?

2022-11-23  Jakub Jelinek  <jakub@redhat.com>

	* c.opt (fcontract-assumption-mode=, fcontract-continuation-mode=,
	fcontract-role=, fcontract-semantic=): Add RejectNegative.
	(fcontract-build-level=): Terminate description with dot.
parent 3138db58
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment