refactor msg formatting, add CLUTCHDUMP
- remove show_* methods.
This commit is contained in:
parent
b3a04a88a7
commit
819a2ebf15
4 changed files with 195 additions and 68 deletions
18
tests/t-dump.cpp
Normal file
18
tests/t-dump.cpp
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
#include <iostream>
|
||||
|
||||
#include "../clutchlog/clutchlog.h"
|
||||
|
||||
int main(/*const int argc, char* argv[]*/)
|
||||
{
|
||||
#ifdef WITH_CLUTCHLOG
|
||||
|
||||
auto& log = clutchlog::logger();
|
||||
|
||||
log.out(std::clog);
|
||||
log.threshold(clutchlog::level::xdebug);
|
||||
|
||||
std::vector<std::string> msg = {"hello", "world", "!"};
|
||||
|
||||
CLUTCHDUMP(xdebug, msg);
|
||||
#endif
|
||||
}
|
||||
|
|
@ -27,9 +27,6 @@ int main(/*const int argc, char* argv[]*/)
|
|||
auto& log = clutchlog::logger();
|
||||
|
||||
log.out(std::clog);
|
||||
log.threshold(clutchlog::level::warning);
|
||||
log.file("core");
|
||||
log.func("(main|f)");
|
||||
|
||||
std::clog << "depth: 99; threshold: xdebug; location: .*" << std::endl;
|
||||
log.depth(99);
|
||||
Loading…
Add table
Add a link
Reference in a new issue