diff options
author | Alexandre Oliva <oliva@adacore.com> | 2020-05-26 11:02:21 -0300 |
---|---|---|
committer | Alexandre Oliva <oliva@gnu.org> | 2020-05-26 11:02:21 -0300 |
commit | 6232d02b4fce4c67d39815aa8fb956e4b10a4e1b (patch) | |
tree | 10272b2b66191d25d85ed047c780df380714cacc /gcc/ada/gcc-interface/Makefile.in | |
parent | 1d72079ba3a370d6751953312f0de76d1a1c555d (diff) | |
download | gcc-6232d02b4fce4c67d39815aa8fb956e4b10a4e1b.zip gcc-6232d02b4fce4c67d39815aa8fb956e4b10a4e1b.tar.gz gcc-6232d02b4fce4c67d39815aa8fb956e4b10a4e1b.tar.bz2 |
do not skip validation of switch after %<opt
After the patch that revamped dump and aux outputs, GCC compilation
drivers built without Ada would reject -d* options. Such options
would only be validated because of the %{d*} in Ada lang specs, though
other languages had it as well. Other languages had %< specs that had
to be there before %{d*} %:dumps(), while Ada was missing them.
Adding them to Ada brought the same problem to compilers that had Ada
enabled.
The reason validation failed was that they mishandled %< specs,
advancing past the beginning of the next spec, causing it not to be
handled. Since %{d*} appeared after an odd %<, it was thus ignored.
The logic of validate_switches originally skipped the closing brace
that matched the opening brace, but this shouldn't happen for %<.
Fixed by letting validate_switches know whether it is handling a
braced group or a single atom, and behaving accordingly.
gcc/ChangeLog:
* gcc.c (validate_switches): Add braced parameter. Adjust all
callers. Expected and skip trailing brace only if braced.
Return after handling one atom otherwise.
(DUMPS_OPTIONS): New.
(cpp_debug_options): Define in terms of it.
gcc/ada/ChangeLog:
* gcc-interface/lang-specs.h (ADA_DUMPS_OPTIONS): Define in
terms of DUMPS_OPTIONS. Replace occurrences of %{d*} %:dumps
with it.
Diffstat (limited to 'gcc/ada/gcc-interface/Makefile.in')
0 files changed, 0 insertions, 0 deletions