re PR c++/68265 (Arbitrary syntactic nonsense silently accepted after 'int (*){}' until the next close brace)

PR c++/68265
	* g++.dg/parse/error62.C: New test.

From-SVN: r272525
This commit is contained in:
Marek Polacek 2019-06-20 22:06:36 +00:00 committed by Marek Polacek
parent 966e7f731e
commit c35f57c5bd
2 changed files with 15 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2019-06-20 Marek Polacek <polacek@redhat.com>
PR c++/68265
* g++.dg/parse/error62.C: New test.
2019-06-20 Steven G. Kargl <kargl@gcc.gnu.org>
PR fortran/86587

View File

@ -0,0 +1,10 @@
// PR c++/68265
int main()
{
int (*) {} // { dg-error "expected primary-expression" }
any amount of syntactic nonsense // { dg-error "not declared in this scope" }
on multiple lines, with *punctuation* and ++operators++ even...
will be silently discarded
until the next close brace
}