On 10/20/2017 12:37 PM, Mukesh Kapoor wrote:
Hi,

This patch fixes https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80955.
Handle user-defined literals correctly in lex_string(). An empty string followed by an identifier is
a valid user-defined literal. Don't issue a warning for this case.

a) why do we trigger on the definition of the operator function, and not on the use site?

b) Why is the empty string special cased?  Doesn't the same logic apply to:

int operator "bob"_zero (const char *, size_t) { return 0;}

(that'd be a syntactic error in the C++ parser of course)

nathan

--
Nathan Sidwell

Reply via email to