[OptTable] Fix typo VALUE => VALUES (NFCI) (#121523)
[llvm-project.git] / clang-tools-extra / test / clang-reorder-fields / CStructFieldsOrder.cpp
blob2ed3578df6563f2a816dcc24f06aca04462d4974
1 // RUN: clang-reorder-fields -record-name ::bar::Foo -fields-order z,w,y,x %s -- | FileCheck %s
3 namespace bar {
4 struct Foo {
5 const int* x; // CHECK: {{^ double z;}}
6 int y; // CHECK-NEXT: {{^ int w;}}
7 double z; // CHECK-NEXT: {{^ int y;}}
8 int w; // CHECK-NEXT: {{^ const int\* x}}
9 };
10 } // end namespace bar
12 int main() {
13 const int x = 13;
14 bar::Foo foo = { &x, 0, 1.29, 17 }; // CHECK: {{^ bar::Foo foo = { 1.29, 17, 0, &x };}}
15 return 0;