opnsense-src/test/Preprocessor/output_paste_avoid.c

27 lines
413 B
C
Raw Normal View History

2010-01-01 05:34:51 -05:00
// RUN: %clang_cc1 -E %s -o - | FileCheck -strict-whitespace %s
2009-11-04 10:04:32 -05:00
2009-06-02 13:58:47 -04:00
#define y(a) ..a
A: y(.)
2009-11-04 10:04:32 -05:00
// This should print as ".. ." to avoid turning into ...
// CHECK: A: . . .
2009-06-02 13:58:47 -04:00
#define DOT .
C: ..DOT
2009-11-04 10:04:32 -05:00
// CHECK: C: .. .
2009-06-02 13:58:47 -04:00
#define PLUS +
#define EMPTY
#define f(x) =x=
D: +PLUS -EMPTY- PLUS+ f(=)
2009-11-04 10:04:32 -05:00
// CHECK: D: + + - - + + = = =
2009-06-02 13:58:47 -04:00
#define test(x) L#x
E: test(str)
2009-11-04 10:04:32 -05:00
// Should expand to L "str" not L"str"
// CHECK: E: L "str"
2009-06-02 13:58:47 -04:00