diff options
author | Jakub Jelinek <jakub@redhat.com> | 2025-04-14 19:33:11 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2025-04-14 19:33:11 +0200 |
commit | e0b57c75e6daa1664bea03ce96733bf1ebb38ced (patch) | |
tree | 960814e8389435ee65cae40d0f2d2c961cccff7d /libjava/javax/swing/plaf/basic/BasicDesktopPaneUI$MaximizeAction.h | |
parent | d0b41f3d6d0ace2b0ca57d105cd7fd8361d0b2a8 (diff) | |
download | gcc-e0b57c75e6daa1664bea03ce96733bf1ebb38ced.zip gcc-e0b57c75e6daa1664bea03ce96733bf1ebb38ced.tar.gz gcc-e0b57c75e6daa1664bea03ce96733bf1ebb38ced.tar.bz2 |
cobol: Fix -fmax-errors option [PR119776]
There seems to be inconsistency in the -fmax-errors option
naming. It is a generic option in common.opt (so applies
to all languages) but with the = character in it.
The gcobol.1 man page in one spot documents the generic
option (in the syntax, -fmax-errors=nerror) but in another
spot without the = character.
In common.opt it is
fmax-errors=
Common Joined RejectNegative UInteger Var(flag_max_errors)
-fmax-errors=<number> Maximum number of errors to report.
I hope the cobol addition is just a mistake, having -fmax-errors variant
without = character when Joined Separate would allow to specify
-fmax-errors 10 with the same meaning as -fmax-errors=10
but also -fmax-errors10 with the same meaning which is just weird.
Also, there is no UInteger and RejectNegative on it, so one can
also specific -fno-max-errors42 or -fmax-errors blah.
So, unless the spelling without = is intentional, here is a patch
to just remove it, the common option already should have arranged
for flag_max_errors to be set to the right number.
Or if it is intentional, I guess we'd need to at least add
RejectNegative UInteger (plus using atoi is generally undesirable
anywhere in the compiler because it does no error checking).
And the man page would need to be updated to specify both forms.
2025-04-14 Jakub Jelinek <jakub@redhat.com>
PR cobol/119776
* lang.opt (fmax-errors): Remove.
* lang.opt.urls: Regenerate.
* cobol1.cc (cobol_langhook_handle_option) <case OPT_fmax_errors>:
Remove.
* gcobol.1: Document -fmax-errors=nerror rather than
-fmax-errors nerror.
Diffstat (limited to 'libjava/javax/swing/plaf/basic/BasicDesktopPaneUI$MaximizeAction.h')
0 files changed, 0 insertions, 0 deletions