On 06/25/2013 08:27 AM, Ed Smith-Rowland wrote:
+ else if (token->type == CPP_KEYWORD)
+ {
+ error ("unexpected keyword;"
+ " Remove space between quotes and suffix identifier");
+ return error_mark_node;
+ }
Lower-case 'r' after a semicolon.
After giving the error, let's try to handle it properly anyway to avoid
cascading errors.
+ if (TREE_STRING_LENGTH (string_tree) > 2)
Why 2? I would expect TREE_STRING_LENGTH for "" to be 1 (the NUL).
+ error ("expected empty string after %<operator%> keyword");
+ return error_mark_node;
And let's continue after the error here, too.
+ error ("invalid encoding prefix in literal operator");
return error_mark_node;
And here.
Jason