Make ## token merging on character constants give an error.

This ultimately should be supported, but that will be more work. For now, we just set the string representation to '?', which will usually give an error when merged. (Previously, whatever was at memory location 0 would be treated as the string representation of the token. Frequently this would just be an empty string, leading to no error but incorrect results.)
This commit is contained in:
Stephen Heumann 2022-02-20 16:19:00 -06:00
parent da978932bf
commit 2b062a8392
1 changed files with 3 additions and 0 deletions

View File

@ -4710,6 +4710,9 @@ var
token.lval := result;
end; {else if}
if saveNumber then {TODO: support token merging}
token.numString := @'?';
charStrPrefix := prefix_none; {no prefix for next char/str (so far)}
end; {CharConstant}