[ create a new paste ] login | about

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

C++, pasted on Feb 2:
1
2
3
4
5
6
7
8
9
10
11
struct Example {
private:
  struct iterator {};
public:
  iterator begin();
};

int main() {
  Example e;
  Example::iterator x = e.begin();
}


Output:
1
2
3
In function 'int main()':
Line 3: error: 'struct Example::iterator' is private
compilation terminated due to -Wfatal-errors.


Create a new paste based on this one


Comments: