37 std::string generate_error(
const char* msg,
const char* file,
unsigned line)
42 error_msg.append(msg);
44 error_msg.append(
" (");
48 error_msg.append(
"thrown at ");
53 error_msg.append(buff);
55 error_msg.push_back(
':');
59 error_msg.push_back(
')');
64 void expect::throw_(std::error_code ec,
const char* msg,
const char* file,
unsigned line)
67 throw std::system_error{ec, generate_error(msg, file, line)};
68 throw std::system_error{ec};
declaration and default definition for the functions used the API
static void buildBaseFilename(const std::string &fullPath, char buff[], std::size_t limit=base::consts::kSourceFilenameMaxLength, const char *seperator=base::consts::kFilePathSeperator)
builds base filename and puts it in buff
static void throw_(std::error_code ec, const char *msg, const char *file, unsigned line)
std::string to_string(t_connection_type type)