Home | History | Annotate | Download | only in dcl.constexpr

Lines Matching defs:int

14   NonLiteral(int) {}
18 operator int() const { return 0; }
22 virtual int ImplicitlyVirtual() const = 0; // expected-note {{overridden virtual function}}
25 int ImplicitlyVirtual() const;
32 constexpr int f() const;
35 virtual constexpr int ExplicitlyVirtual() const { return 0; } // expected-error {{virtual function cannot be constexpr}}
37 constexpr int ImplicitlyVirtual() const { return 0; } // expected-error {{virtual function cannot be constexpr}}
50 constexpr int NonLiteralParam(NonLiteral) const { return 0; } // expected-error {{constexpr function's 1st parameter type 'NonLiteral' is not a literal type}}
51 typedef int G(NonLiteral) const;
55 constexpr int Deleted() const = delete;
72 int n = 0;
82 constexpr int SelfParam(U) const;
86 constexpr int F() const { return 0; } // expected-error {{constexpr member function not allowed in struct with virtual base class}}
90 constexpr int AllowedStmtsCXX11() {
99 typedef int I;
101 using J = int;
102 using K = int[sizeof(I) + sizeof(J)];
117 constexpr int DisallowedStmtsCXX1Y_1() {
122 constexpr int DisallowedStmtsCXX1Y_2() {
128 constexpr int DisallowedStmtsCXX1Y_3() {
133 constexpr int DisallowedStmtsCXX1Y_4() {
138 constexpr int DisallowedStmtsCXX1Y_5() {
140 static constexpr int n = 123; // expected-error {{static variable not permitted in a constexpr function}}
143 constexpr int DisallowedStmtsCXX1Y_6() {
145 thread_local constexpr int n = 123; // expected-error {{thread_local variable not permitted in a constexpr function}}
148 constexpr int DisallowedStmtsCXX1Y_7() {
150 int n; // expected-error {{variables defined in a constexpr function must be initialized}}
154 constexpr int ForStmt() {
155 for (int n = 0; n < 10; ++n)
161 constexpr int VarDecl() {
162 int a = 0;
168 constexpr int ConstexprVarDecl() {
169 constexpr int a = 0;
175 constexpr int VarWithCtorDecl() {
191 constexpr int FuncDecl() {
192 constexpr int ForwardDecl(int);
198 constexpr int ClassDecl1() {
205 constexpr int ClassDecl2() {
212 constexpr int ClassDecl3() {
219 constexpr int NoReturn() {} // expected-error {{no return statement in constexpr function}}
220 constexpr int MultiReturn() {
236 constexpr int f(int k) {
240 int kGlobal; // expected-note {{here}}
241 constexpr int f() { // expected-error {{constexpr function never produces a constant expression}}
263 constexpr int square(int x) {
269 constexpr int abs(int x) {
277 constexpr int first(int n) {
278 static int value = n; // expected-error {{static variable not permitted}}
281 constexpr int uninit() {
282 int a; // expected-error {{must be initialized}}
285 constexpr int prev(int x) {
292 constexpr int g(int x, int n) {
293 int r = 1;