]> granicus.if.org Git - clang/commit
When we expect two arguments but have zero, make sure to add
authorChris Lattner <sabre@nondot.org>
Wed, 13 May 2009 00:55:26 +0000 (00:55 +0000)
committerChris Lattner <sabre@nondot.org>
Wed, 13 May 2009 00:55:26 +0000 (00:55 +0000)
commit9fc9e77c2fd15a88bd19ff3fdc9eb9716742f720
tree4b28e9426a6e845dd16d8062f3884cd4b49ac0bd
parent09d04e5097034d8dfb9fcfceb457f6924cdd2417
When we expect two arguments but have zero, make sure to add
two empty arguments.  Also, add an assert so that this bug
manifests as an assertion failure, not a valgrind problem.

This fixes rdar://6880648 - [cpp] crash in ArgNeedsPreexpansion

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@71616 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Lex/MacroArgs.cpp
lib/Lex/PPMacroExpansion.cpp
test/Preprocessor/macro_expand.c