cex: rename -Wcounterexample as -Wcounterexamples, and support -Wcex

Plural vs. singular is always a problem...

But we already have conflicts-sr and conflicts-rr, so counterexamples
makes more sense than counterexample.  Besides, -Wcounterexample will
still be accepted as an unambiguous prefix of -Wcounterexamples.

Add -Wcex as a convenient alias.

While at it, use only "counterexample", never "counter example".

* src/complain.h, src/complain.c
(Wcounterexample, warning_counterexample): Rename as...
(Wcounterexamples, warning_counterexamples): these.
(argmatch_warning_docs): Rename -Wcounterexample as -Wcounterexamples.
(argmatch_warning_args): Likewise.
Add support for -Wcex.
Adjust dependencies.
This commit is contained in:
Akim Demaille
2020-06-10 07:35:47 +02:00
parent a53c6026cd
commit d2acc4b401
6 changed files with 22 additions and 22 deletions

View File

@@ -46,7 +46,7 @@ typedef enum
{
warning_conflicts_rr,
warning_conflicts_sr,
warning_counterexample,
warning_counterexamples,
warning_dangling_alias,
warning_deprecated,
warning_empty_rule,
@@ -107,7 +107,7 @@ typedef enum
Wconflicts_rr = 1 << warning_conflicts_rr,
Wconflicts_sr = 1 << warning_conflicts_sr,
Wcounterexample = 1 << warning_counterexample,
Wcounterexamples = 1 << warning_counterexamples,
Wdangling_alias = 1 << warning_dangling_alias,
Wdeprecated = 1 << warning_deprecated,
Wempty_rule = 1 << warning_empty_rule,
@@ -124,7 +124,7 @@ typedef enum
/**< All above warnings. */
Weverything = ~complaint & ~fatal & ~silent,
Wall = Weverything & ~Wcounterexample & ~Wdangling_alias & ~Wyacc
Wall = Weverything & ~Wcounterexamples & ~Wdangling_alias & ~Wyacc
} warnings;
/** Whether the warnings of \a flags are all unset.