Marco wrote:
The following code compiles with Microsoft Visual Studio but not with
GNU (version 3.3.3 running on Linux). Is there a way to inhert from
exception in GNU?
How about you tell us the exact errormessage? It might also be worth
reporting the version of the comparison environment.
#include <iostream>
#include <exception>
class Toto : public exception
1st mistake (as already pointed out) it's std::exception.
{
public:
virtual const char* what() { return "tutu";}
This function signature is simply wrong.