This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] fix PR c++/14136: Duplicate error message


Volker Reichelt wrote:

In fact, cp_parser_simulate_error in fact calls
!cp_parser_committed_to_tentative_parse, but does some additional
stuff (like marking the attempt as failed), too.
So here's an updated version which uses cp_parser_simulate_error
instead of just cp_parser_committed_to_tentative_parse.

no this change is not right. the construct is syntatically valid (it should parse), but it is semantically invalid - hence the error.

Your first patch was better, as it did not change the parse.  However,
why do we parse this bit twice anyway?

nathan
--
Nathan Sidwell    ::   http://www.codesourcery.com   ::     CodeSourcery LLC
nathan@codesourcery.com    ::     http://www.planetfall.pwp.blueyonder.co.uk


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]