Lines Matching refs:constexpr
7 constexpr int f(void *) { return 0; } in f()
8 constexpr int f(...) { return 1; } in f()
9 constexpr int g1() { return f(0); } in g1()
10 constexpr int g2(int n) { return f(n); } in g2()
11 constexpr int g3(int n) { return f(n*0); } in g3()
14 constexpr int c = 5;
15 constexpr int h() { return c; } in h()
17 constexpr int c = 0;
18 constexpr int g4() { return N::h(); } in g4()
31 constexpr int f(bool b) in f()
33 constexpr int f() { return throw 0, 0; } // expected-error {{constexpr function never produces a co… in f()
36 constexpr B(int x) : i(0) { } in B()
43 …constexpr D() : B(global) { } // expected-error {{constexpr constructor never produces a constant … in D()
50 constexpr int Comma(int n) { return // expected-error {{constexpr function never produces a constan… in Comma()
57 constexpr int BinaryOp1(int n) { return n + ng; } // expected-error {{never produces}} expected-not… in BinaryOp1()
58 constexpr int BinaryOp2(int n) { return ng + n; } // expected-error {{never produces}} expected-not… in BinaryOp2()
61 constexpr double BinaryOp1(double d) { return d + dg; } // expected-error {{never produces}} expect… in BinaryOp1()
62 constexpr double BinaryOp2(double d) { return dg + d; } // expected-error {{never produces}} expect… in BinaryOp2()
64 constexpr int Add(int a, int b, int c) { return a + b + c; } in Add()
65 constexpr int FunctionArgs(int a) { return Add(a, ng, a); } // expected-error {{never produces}} ex… in FunctionArgs()
68 constexpr S InitList(int a) { return { a, ng }; }; // expected-error {{never produces}} expected-no… in InitList()
69 constexpr S InitList1a(int a) { return S{ a, ng }; }; // expected-error {{never produces}} expected… in InitList1a()
70 constexpr S InitList2(int a) { return { a, a, { ng } }; }; // expected-error {{never produces}} exp… in InitList2()
71 constexpr S InitList3(int a) { return a ? S{ a, a } : S{ a, ng }; }; // ok in InitList3()
73 constexpr int LogicalAnd1(int n) { return n && (throw, 0); } // ok in LogicalAnd1()
74 constexpr int LogicalAnd2(int n) { return 1 && (throw, 0); } // expected-error {{never produces}} e… in LogicalAnd2()
76 constexpr int LogicalOr1(int n) { return n || (throw, 0); } // ok in LogicalOr1()
77 constexpr int LogicalOr2(int n) { return 0 || (throw, 0); } // expected-error {{never produces}} ex… in LogicalOr2()
79 constexpr int Conditional1(bool b, int n) { return b ? n : ng; } // ok in Conditional1()
80 constexpr int Conditional2(bool b, int n) { return b ? n * ng : n + ng; } // expected-error {{never… in Conditional2()
83 constexpr bool BcpCall(int n) { in BcpCall()
90 template<typename T> constexpr T cmin(T a, T b) { in cmin()
96 constexpr X() {} in X()
105 constexpr Y() {} in Y()
106 constexpr int get() { return T(); } in get()
128 static constexpr int f() { return n; } in f()
139 constexpr void f() { throw; } // expected-error {{never produces}} expected-note {{subexpression}} in f()