This commit is contained in:
2024-02-23 02:27:06 +06:00
parent 015f406eba
commit e47f497f8c
17 changed files with 293 additions and 226 deletions

19
src/UsefulException.cpp Normal file
View File

@@ -0,0 +1,19 @@
#include "UsefulException.hpp"
#include <sstream>
namespace GraphC {
UsefulException_::UsefulException_(std::string _message, std::string _file, std::string _func, int _line_n)
: message(_message), file(_file), function(_func), line_n(_line_n)
{
std::stringstream ss;
ss<<message<<'\n';
ss<<file<<':'<<_line_n<<" in "<<function;
complete_text = ss.str();
}
const char* UsefulException_::what() {
return complete_text.c_str();
}
}