[ create a new paste ] login | about

Link: http://codepad.org/tjYgwnYe    [ raw code | fork ]

C++, pasted on Apr 29:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
template<bool> struct a_t;

template<> struct a_t<true> {
    template<int> struct b {};
};

template<> struct a_t<false> {
    enum { b };
};

typedef a_t<sizeof(void*)==sizeof(int)> a;

enum { c, d };
int main() {
    a::b<c>d; // declaration or expression?
}


Output:
No errors or program output.


Create a new paste based on this one


Comments: