Assembly GNU as.macro占位符,后跟字符

Assembly GNU as.macro占位符,后跟字符,assembly,gnu,Assembly,Gnu,在GNU汇编程序中,我定义了这样一个宏 .macro test_cond condition, index STR\conditionB r4, [r6, #\index*17] .endm test_cond EQ, 0 它应该扩展到 STREQB r4, [r6, #0*17] 相反,它失败了 bad instruction `streq\conditionB r4,[r6,#0*17]' 有没有办法让宏中的占位符后面紧跟着一个字符?使用\()构造将宏参数与其后面的字符分开:

在GNU汇编程序中,我定义了这样一个宏

.macro test_cond condition, index
    STR\conditionB r4, [r6, #\index*17]
.endm

test_cond EQ, 0
它应该扩展到

STREQB r4, [r6, #0*17]
相反,它失败了

bad instruction `streq\conditionB r4,[r6,#0*17]'
有没有办法让宏中的占位符后面紧跟着一个字符?

使用
\()
构造将宏参数与其后面的字符分开:

.macro test_cond condition, index
    STR\condition\()B r4, [r6, #\index*17]
.endm