PR c++/62314: add fixit hint for "expected ';' after class definition"
authorDavid Malcolm <dmalcolm@redhat.com>
Tue, 5 Jul 2016 15:50:54 +0000 (15:50 +0000)
committerDavid Malcolm <dmalcolm@gcc.gnu.org>
Tue, 5 Jul 2016 15:50:54 +0000 (15:50 +0000)
commit84ca38932bd55f3fc058f4d17c46d132a3745042
tree9140a8ba92a6650daa38dd111c0813c0b04dadc7
parent20d0bfcefd6caf09c23113732edd98241a46af56
PR c++/62314: add fixit hint for "expected ';' after class definition"

gcc/cp/ChangeLog:
PR c++/62314
* parser.c (cp_parser_class_specifier_1): When reporting
missing semicolons, use a fixit-hint to suggest insertion
of a semicolon immediately after the closing brace,
offsetting the reported column accordingly.

gcc/testsuite/ChangeLog:
PR c++/62314
* gcc/testsuite/g++.dg/parse/error5.C: Update column
number of missing semicolon error.
* g++.dg/pr62314-2.C: New test case.

From-SVN: r238008
gcc/cp/ChangeLog
gcc/cp/parser.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/parse/error5.C
gcc/testsuite/g++.dg/pr62314-2.C [new file with mode: 0644]