[llvm-commits] [RFC, AsmParser] How to handle '$' like '.' ?

Hi Ulrich,

I started working on our target's parser recently and I have a similar issue with colons. The Hexagon assembler allows ':' in register assignment statements. An example would be, "r5:4 = r3:2" or "r5:4 = combine(r3, r2)" either of which will assign the contents of registers 3 and 2 to registers 5 and 4 respectively.

I would like to add method, "colonIsLabel()" to the MCTargetAsmParser and then let this target defined method look at the statement. If it is not a label then break and let parseInstruction handle the statement otherwise treat it as a label.

I have not seen any replies to your RFC but do you feel like this approach would be reasonable. Given the irregularities of assembly it seems like target specific methods will be needed for other notations as well.