[C++ PATCH] more TU parsing refactoring
authorNathan Sidwell <nathan@acm.org>
Fri, 12 Oct 2018 18:44:48 +0000 (18:44 +0000)
committerNathan Sidwell <nathan@gcc.gnu.org>
Fri, 12 Oct 2018 18:44:48 +0000 (18:44 +0000)
commit7fa072dea587ff70bee5e059f3cd31a7b2ce9a3c
tree1082f25d05a37c2f027f3ccf3aaf511f018948ba
parent47b92d22d3aea04ce6a936c768953dd0406f41c2
[C++ PATCH] more TU parsing refactoring

https://gcc.gnu.org/ml/gcc-patches/2018-10/msg00788.html
* parser.h (struct cp_parser): Drop implicit_extern_c.
* parser.c (cp_debug_parser): Drop implicit_extern_c.
(cp_parser_new): Likewise.
(cp_parser_translation_unit): Handle implicit extern c here.  Call
cp_parser_toplevel_declaration.
(cp_parser_toplevel_declaration): New, broken out of ...
(cp_parser_declaration_seq_opt): ... here.  Call it.  Drop
implicit extern C handling.

From-SVN: r265127
gcc/cp/ChangeLog
gcc/cp/parser.c
gcc/cp/parser.h