[PATCH v2 11/17] MIPS: correct macro use in gas and ld testsuites

Jan Beulich jbeulich@suse.com
Mon Jul 15 14:08:34 GMT 2024


On 15.07.2024 14:11, Maciej W. Rozycki wrote:
> On Fri, 12 Jul 2024, Jan Beulich wrote:
> 
>> Whitespace in macro arguments either needs quoting / parenthesizing to
>> reliably not be mistaken for an argument separator, or respective macro
>> parameters need to be marked as covering all remaining arguments. The
>> former appears more appropriate here, as the macro parameters already
>> have ":req".
> 
>  Thank you, however these macros interpret the argument as an arithmetic 
> expression, so I think it will be more natural to parenthesise it rather 
> than quote.

Okay, I've changed it to that. Using quotes is overall cheaper parsing-
wise, but I'm absolutely going to respect your request. I won't re-post
just for this, though.

>  I note that this requirement is not documented in the GAS 
> manual (or I cannot spot it).

There's surprisingly little detail on how to (correctly and compatibly)
use / invoke macros. There's no mention at all on how to separate macro
arguments; the only hint is that macro parameters are explicitly
mentioned as being allowed to be only whitespace separated (by itself
already causing problems which aren't mentioned).

Jan



More information about the Binutils mailing list