[PATCH 07/11] gas: consistently drop trailing whitespace when scrubbing

Maciej W. Rozycki macro@orcam.me.uk
Mon Jul 1 11:05:15 GMT 2024


On Mon, 1 Jul 2024, Jan Beulich wrote:

> >> In the MIPS testsuite adjustments I wasn't sure how exactly to make the
> >> necessary changes: I could also have zapped the two blanks each, but
> >> then I wondered why they were part of the expectations in the first
> >> place.
> > 
> >  Please do.
> 
> Done locally; I won't post a v2 just for this, though.

 Thank you, and agreed.

> >  The only reason I can think of why the patterns are such as they are is 
> > that they need to match the output as it has been produced.  It made no 
> > sense to make whitespace matching optional when said whitespace is always 
> > there.
> 
> But the purpose of those tests isn't the _exact_ output that gas would
> produce, is it? The presence / absence of whitespace in most tests
> really is entirely unrelated to what is being tested. Just to mention
> it ...

 Of course, but something has to be placed there as the pattern to match 
against and taking the message produced literally, whitespace or not, is 
the simplest and most obvious choice.

 Also think of the MIPS tests as coverage for your good work; is there any 
other?

  Maciej


More information about the Binutils mailing list