]> granicus.if.org Git - clang/commit
Remove an assert that's not true on invalid code.
authorNico Weber <nicolasweber@gmx.de>
Sun, 4 Jan 2015 20:32:12 +0000 (20:32 +0000)
committerNico Weber <nicolasweber@gmx.de>
Sun, 4 Jan 2015 20:32:12 +0000 (20:32 +0000)
commit71729a81a12da342e4a5a81f0984052b145f1c12
tree5f216bce4ba485076c29368cf17cbabd4c965e53
parentc7b7d666adf7664c5fd53d2590ef3dce63e4f4fd
Remove an assert that's not true on invalid code.

r185773 added an assert that checked that a CXXUnresolvedConstructExpr either
has a valid rparen, or exactly one argument.  This doesn't have to be true for
invalid inputs.  Convert the assert to an if, and add a test for this case.

Found by SLi's afl bot.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@225140 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/AST/ExprCXX.h
test/Misc/ast-dump-invalid.cpp [new file with mode: 0644]
test/SemaCXX/return.cpp