Single character constants
David Betz
Posts: 14,516
Is there a way to use single character constants in GAS? I think they are normally indicated by single quotes but we've repurposed those to introduce comments. Is there an alternate way to do character constants? I want to do something like this:
hello byte 'H', 'e', 'l', 'l', 'o', ',', ' ', 'W', 'o', 'r', 'l', 'd', '!', 15, 12, 0
Comments
No, unfortunately there's no way to do single character constants in GAS. What you wanted though could be accomplished by something like:
Would something like
also work?
===Jac
No.
The single character version David originally posted would be the normal way to do this, but as he mentioned the single quote is co-opted for comments.
Perhaps we should revert GAS to using semicolon for comments, but that opens up a whole other can of worms regarding PASM compatibility, so perhaps not.
Eric