language: C++ 4.7.2 (gcc-4.7.2)
date: 804 days 14 hours ago
link:
visibility: public
1
2
3
4
5
6
7
8
9
10
11
12
13
#include <iostream>
 
using namespace std;
 
class X {
    static const int x;
    enum { y = &x };
};
 
int main() {
        
        return 0;
}
prog.cpp:7: error: ‘X::x’ cannot appear in a constant-expression
prog.cpp:7: error: `&' cannot appear in a constant-expression