Test case for #1076 (Invalid number of character ({). Can't process file.)

This commit is contained in:
Reijo Tomperi 2009-12-13 22:36:42 +02:00
parent 4dc8794c69
commit 42c2437f78
1 changed files with 9 additions and 0 deletions

View File

@ -1128,6 +1128,15 @@ private:
"foo\n";
ASSERT_EQUALS("\nfoo\n", OurPreprocessor::expandMacros(filedata));
}
{
const char filedata[] =
"#define B(A1, A2) } while (0)\n"
"#define A(name) void foo##name() { do { B(1, 2); }\n"
"A(0)\n"
"A(1)\n";
TODO_ASSERT_EQUALS("\n\nvoid foo0(){do{}while(0);}\nvoid foo1(){do{}while(0);}\n", OurPreprocessor::expandMacros(filedata));
}
}
void macro_mismatch()