[ create a new paste ] login | about

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

C++, pasted on Feb 17:
1
2
3
4
5
6
7
8
9
10
11
12
13
#include <iostream>
using namespace std;

class I {
    virtual void method(){};
protected:
    ~I() {}
};

int main(){
    I base;
    return 0;
}


Output:
1
2
3
In function 'int main()':
Line 7: error: 'I::~I()' is protected
compilation terminated due to -Wfatal-errors.


Create a new paste based on this one


Comments: