Clang Project

clang_source_code/test/Analysis/Inputs/system-header-simulator-for-cxx-uninitialized-object.h
1// Like the compiler, the static analyzer treats some functions differently if
2// they come from a system header -- for example, it is assumed that system
3// functions do not arbitrarily free() their parameters, and that some bugs
4// found in system headers cannot be fixed by the user and should be
5// suppressed.
6
7#pragma clang system_header
8
9struct RecordInSystemHeader {
10  int a;
11  int b;
12};
13
14template <class T>
15struct ContainerInSystemHeader {
16  T &t;
17  ContainerInSystemHeader(T& t) : t(t) {}
18};
19