Assembly macros instantiation problem


I've noticed a following strange behavior:
clang-3.2 fails to compile/parse any assembly code that invokes macros which named arguments contains non alphanumeric characters.
For example, compilation of the following code snippet would fail with "Parameter not found" error:
.macro mov_macro reg_1, reg_2
movl %\reg_1, %\reg_2
mov_macro eax, ebx

Although, if one removes underscores from mov_macro argument names, compilation would succeed.
Such behavior is due to the glitch in AsmParser::expandMacro() logic: it treats first non-alphanumeric character as the end of argument instantiation token.

Following patch fixes the issue (IsIdentifierChar routine implementation was borrowed from lib/MC/MCParser/AsmLexer.cpp):