llvm-capstone/clang/test/Preprocessor/pp-record.c
Argyrios Kyrtzidis 832de9fcf1 [preprocessing record] Have the MacroDefinitions map point to the MacroDefinition object instead
its index in the preprocessed entities vector.

This is because the order of the entities in the vector can change in some (uncommon) cases.

llvm-svn: 175907
2013-02-22 18:35:59 +00:00

35 lines
420 B
C

// RUN: %clang_cc1 -fsyntax-only -detailed-preprocessing-record %s
// http://llvm.org/PR11120
#define STRINGIZE(text) STRINGIZE_I(text)
#define STRINGIZE_I(text) #text
#define INC pp-record.h
#include STRINGIZE(INC)
CAKE;
#define DIR 1
#define FNM(x) x
FNM(
#if DIR
int a;
#else
int b;
#endif
)
#define M1 c
#define M2 int
#define FM2(x,y) y x
FM2(M1, M2);
#define FM3(x) x
FM3(
#define M3 int x2
)
M3;