diff --git a/include/bits/soi-dbg.hpp b/include/bits/soi-dbg.hpp index fbde5ab..6ba3cce 100644 --- a/include/bits/soi-dbg.hpp +++ b/include/bits/soi-dbg.hpp @@ -94,6 +94,7 @@ template std::string sanitized_type_name() { return sanitize_type(std::string(t.data, t.size)); } + inline std::string extract_method_name(std::string const& pretty_function) { size_t colons = pretty_function.find("::"); size_t begin = pretty_function.substr(0,colons).rfind(" ") + 1; @@ -133,7 +134,6 @@ bool are_colors_enabled() { // ---------------------------------------------------------------------------- // init and static variables -static bool colors_enabled = false; static const char *ANSI_DEBUG = ""; static const char *ANSI_EXPRESSION = ""; static const char *ANSI_VALUE = ""; @@ -143,7 +143,6 @@ static const char *ANSI_RESET = ""; void dbg_init(bool with_colors) { if (with_colors) { - bool colors_enabled = true; ANSI_DEBUG = "\x1b[37m"; ANSI_EXPRESSION = "\x1b[36m"; ANSI_VALUE = "\x1b[01m"; @@ -151,7 +150,6 @@ void dbg_init(bool with_colors) { ANSI_MESSAGE = "\x1b[31;01m"; ANSI_RESET = "\x1b[0m"; } else { - bool colors_enabled = false; ANSI_DEBUG = ""; ANSI_EXPRESSION = ""; ANSI_VALUE = "";