Re: [PATCH] Fix location of typeid() (PR c++/80014)

2017-03-15 Thread Jason Merrill
On Tue, Mar 14, 2017 at 9:05 PM, David Malcolm wrote: > OK for trunk now, or should this wait until stage 1? Stage 1. > + cp_token *close_paren = cp_parser_require (parser, CPP_CLOSE_PAREN, > + RT_CLOSE_PAREN); > +

[PATCH] Fix location of typeid() (PR c++/80014)

2017-03-14 Thread David Malcolm
PR c++/80014 reports an issue where no caret is printed when issuing an error for this bogus code: !typeid(void); Root cause is that we're not setting up the location for the cp_expr for the typeid expression, so that !typeid(void) has start == caret at the '!', but finish ==