Description
The following escape sequences must be supported and parsed correctly:
1)
2)
{ fn X}3)
{ fn X}4)
{ \n X}Etc. That is, irrespective of whitespaces, everything must be parsed correctly. I propose to rely on Character.isWhitespace, not on regexp. That is, once { is found, we should simply skip all following whitespaces, then get the token, then possibly skip more whitespaces.