Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / Analysis / cxx-uninitialized-object-notes-as-warnings.cpp
blob33f7b0dba07e2887722858ad2d994f4e5c2b3fa1
1 // RUN: %clang_analyze_cc1 -analyzer-checker=core,optin.cplusplus.UninitializedObject \
2 // RUN: -analyzer-config optin.cplusplus.UninitializedObject:NotesAsWarnings=true \
3 // RUN: -analyzer-config optin.cplusplus.UninitializedObject:CheckPointeeInitialization=true \
4 // RUN: -std=c++11 -verify %s
6 class NotesAsWarningsTest {
7 int a;
8 int b;
9 int dontGetFilteredByNonPedanticMode = 0;
11 public:
12 NotesAsWarningsTest() {} // expected-warning{{uninitialized field 'this->a'}}
13 // expected-warning@-1{{uninitialized field 'this->b'}}
16 void fNotesAsWarningsTest() {
17 NotesAsWarningsTest();