Hi folks,
hexadecimal-escape-sequence:
\x hexadecimal-digit-sequence
hexadecimal-escape-sequence hexadecimal-digit
\x{ simple-hexadecimal-digit-sequence }
The combination of the 2nd and 3rd rules seems to say that \x{20}20 should be parsed as a hex escape sequence (presumably representing u+2020). Octal doesn't have this issue as octal-escape-sequence doesn't have a recursive definition.
I tried this on Godbolt. GCC and Clang interpret '\x{20}20' as a multicharacter literal and "\x{20}{20}" as the string " 20". MSVC and icc appear not to support \x{}.
I'd guess this isn't intentional as it would defeat the purpose of having \x{} sequences? At least two implementations seem to agree.
Fraser