Home | History | Annotate | Download | only in Preprocessor
      1 // RUN: %clang_cc1 -E %s | grep '1: aaab 2'
      2 // RUN: %clang_cc1 -E %s | grep '2: 2 baaa'
      3 // RUN: %clang_cc1 -E %s | grep '3: 2 xx'
      4 
      5 #define a(n) aaa ## n
      6 #define b 2
      7 1: a(b b)   // aaab 2    2 gets expanded, not b.
      8 
      9 #undef a
     10 #undef b
     11 #define a(n) n ## aaa
     12 #define b 2
     13 2: a(b b)   // 2 baaa    2 gets expanded, not b.
     14 
     15 #define baaa xx
     16 3: a(b b)   // 2 xx
     17 
     18