Crash even less on malformed attributes in an incorrect location.
authorNico Weber <nicolasweber@gmx.de>
Mon, 29 Dec 2014 21:56:22 +0000 (21:56 +0000)
committerNico Weber <nicolasweber@gmx.de>
Mon, 29 Dec 2014 21:56:22 +0000 (21:56 +0000)
commit36de3a25c2372d084ec329e66441c1fdadb4c727
tree408920586a208c74a4a52bc91a50deb0b2fe5aa2
parent651b72095b64a5add9e0f255bd8f6a5df6dfff07
Crash even less on malformed attributes in an incorrect location.

This is a follow-up to r224915.  This adds a bit more line noise to the tests
added in that revision to make sure the parser is ready for a toplevel decl
after each incorrect line.  Use this to move the tests up to where they belong.
This uncovered that the early return was missing a call to
ActOnTagDefinitionError(), so add that. (Also fixes at least one of the crashes
on SLi's bot.)

llvm-svn: 224958
clang/lib/Parse/ParseDeclCXX.cpp
clang/test/Parser/cxx0x-attributes.cpp