Does C++ have an equivalent to .NET's NotImplementedException?

In the spirit of @dustyrockpyle, I inherit from std::logic_error but I use that class's string constructor, rather than overriding what()

class NotImplemented : public std::logic_error
{
public:
    NotImplemented() : std::logic_error("Function not yet implemented") { };
};

You can inherit from std::logic_error, and define your error message that way:

class NotImplementedException : public std::logic_error
{
public:
    virtual char const * what() const { return "Function not yet implemented."; }
};

I think doing it this way makes catching the exception more explicit if that's actually a possibility. Reference to std::logic_error: http://www.cplusplus.com/reference/stdexcept/logic_error/


Since this is just a temporary exception that does not carry any application meaning, you can just throw a char const* :

int myFunction(double d) {
    throw "myFunction is not implemented yet.";
}