This is the mail archive of the gcc@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: Error handling in the new C++ parser


There seems to be no effort to skip to a sychronizing token
(like ';' or ')') after a normal syntax error, like the old bison
parser did.
It does that when it wants to do that.

There's no need to attempt immediately recovery after missing one
required token; we can wait util it's convenient.

Look for functions with names like cp_parser_skip* to find places where
we skip ahead until something sensible shows up.

I'm sure the error recovery can be improved, but it does OK most of
the time.

--
Mark Mitchell                mark@codesourcery.com
CodeSourcery, LLC            http://www.codesourcery.com


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