"Undefined Symbols" when inheriting from stdexcept classes
- by Austin Hyde
Here is an exception defined in <stdexcept>:
class length_error : public logic_error
{
public:
explicit length_error(const string& __arg);
};
Here is my exception:
class rpn_expression_error : public logic_error
{
public:
explicit rpn_expression_error(const string& __arg);
};
Why do I get this error when <stdexcept> does not?
Undefined symbols:
rpn_expression_error::rpn_expression_error(/*string*/ const&), referenced from:
...
ld: symbol(s) not found