[clang] Implement lifetime analysis for lifetime_capture_by(X) (#115921)
[llvm-project.git] / clang / test / Format / dump-config-list-override.cpp
blobdf4c6ad1333efdc725abd8395fe2e2cdcafb6dbb
1 /// Check that the ForEachMacros, etc. config entries replace default values instead of appending
2 /// FIXME: clang-format currently start overriding at index 0 (keeping the remaining
3 /// values) instead of either appending or completely replacing the values.
4 /// This behaviour is highly confusing. For now this test documents the current state.
5 // RUN: clang-format -style="{BasedOnStyle: LLVM}" -dump-config %s | \
6 // RUN: FileCheck %s --check-prefixes=CHECK,DEFAULT
7 // RUN: clang-format -style="{BasedOnStyle: LLVM, ForEachMacros: ['OVERRIDE_FOREACH']}" -dump-config %s | \
8 // RUN: FileCheck %s --check-prefixes=CHECK,OVERRIDE,FIXME-SHOULD-NOT-BE
9 // RUN: clang-format -style="{BasedOnStyle: LLVM, ForEachMacros: ['M1', 'M2', 'M3', 'M4']}" -dump-config %s | \
10 // RUN: FileCheck %s --check-prefixes=CHECK,MORE-ENTRIES-THAN-DEFAULT
13 // CHECK-LABEL: ForEachMacros:
14 // DEFAULT-NEXT: {{^ }}- foreach
15 // DEFAULT-NEXT: {{^ }}- Q_FOREACH
16 // DEFAULT-NEXT: {{^ }}- BOOST_FOREACH
17 // OVERRIDE-NEXT: {{^ }}- OVERRIDE_FOREACH
18 // FIXME-SHOULD-NOT-BE-NEXT: {{^ }}- Q_FOREACH
19 // FIXME-SHOULD-NOT-BE-NEXT: {{^ }}- BOOST_FOREACH
20 // MORE-ENTRIES-THAN-DEFAULT-NEXT: {{^ }}- M1
21 // MORE-ENTRIES-THAN-DEFAULT-NEXT: {{^ }}- M2
22 // MORE-ENTRIES-THAN-DEFAULT-NEXT: {{^ }}- M3
23 // MORE-ENTRIES-THAN-DEFAULT-NEXT: {{^ }}- M4
24 // CHECK-NEXT: {{^[F-Z]}}