Home | History | Annotate | Download | only in Analysis

Lines Matching defs:Trivial

7 struct Trivial {
8 Trivial(int x) : value(x) {}
12 struct NonTrivial : public Trivial {
13 NonTrivial(int x) : Trivial(x) {}
18 Trivial getTrivial() {
19 return Trivial(42); // no-warning
22 const Trivial &getTrivialRef() {
23 return Trivial(42); // expected-warning {{Address of stack memory associated with temporary object of type 'Trivial' returned to caller}}
36 struct TrivialSubclass : public Trivial {
37 TrivialSubclass(int x) : Trivial(x), anotherValue(-x) {}
62 const Trivial &baseRef = getTrivialSub();
68 struct Derived : public Trivial {
69 Derived(int value) : Trivial(value), value2(-value) {}
76 const Trivial * const &pointerRef = &obj;
241 static const Trivial &ref = getTrivial();
244 static const Trivial &directRef = Trivial(42);
248 thread_local static const Trivial &threadRef = getTrivial();
251 thread_local static const Trivial &threadDirectRef = Trivial(42);