#ifndef PORYGONLANG_EVALUATIONEXCEPTION_HPP #define PORYGONLANG_EVALUATIONEXCEPTION_HPP #include #include using namespace std; class EvaluationException : std::exception { string _message; public: explicit EvaluationException(string message){ _message = message; } const string defaultErrorText = "An evaluation exception occurred: "; const char* what() const noexcept final{ return (defaultErrorText + _message).c_str(); } }; #endif //PORYGONLANG_EVALUATIONEXCEPTION_HPP