brintos

brintos / llvm-project-archived public Read only

0
0
Text · 679 B · 8a81fbf Raw
27 lines · cpp
1// RUN: clang-reorder-fields -record-name Foo -fields-order c,e1,e3,e2,a,b %s -- | FileCheck %s2 3class Foo {4  int a; // Trailing comment for a.5  int b; // Multiline6         // trailing for b.7  // Prefix comments for c.8  int c;9 10  /*c-like*/ int e1;11  int /*c-like*/ e2;12  int e3 /*c-like*/;13};14 15// Note: the position of the empty line is somewhat arbitrary.16 17// CHECK:       // Prefix comments for c.18// CHECK-NEXT:  int c;19// CHECK-NEXT:  /*c-like*/ int e1;20// CHECK-NEXT:  int e3 /*c-like*/;21// CHECK-EMPTY:22// CHECK-NEXT:  int /*c-like*/ e2;23// CHECK-NEXT:  int a; // Trailing comment for a.24// CHECK-NEXT:  int b; // Multiline25// CHECK-NEXT:         // trailing for b.26 27