We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ac5cbe3 commit 5cef3c1Copy full SHA for 5cef3c1
1 file changed
test.cpp
@@ -691,6 +691,18 @@ static void define13()
691
"}", preprocess(code));
692
}
693
694
+static void define14() // #296
695
+{
696
+ const char code[] = "#define bar(x) x % 2\n"
697
+ "#define foo(x) printf(#x \"\\n\")\n"
698
+ "\n"
699
+ " foo(bar(3));\n";
700
+ ASSERT_EQUALS("\n"
701
702
703
+ "printf ( \"bar(3)\" \"\\n\" ) ;", preprocess(code));
704
+}
705
+
706
707
708
static void define_invalid_1()
@@ -3655,6 +3667,7 @@ int main(int argc, char **argv)
3655
3667
TEST_CASE(define11);
3656
3668
TEST_CASE(define12);
3657
3669
TEST_CASE(define13);
3670
+ TEST_CASE(define14); // #296
3658
3671
TEST_CASE(define_invalid_1);
3659
3672
TEST_CASE(define_invalid_2);
3660
3673
TEST_CASE(define_define_1);
0 commit comments