aboutsummaryrefslogblamecommitdiff
path: root/test/log.cc
blob: c059ba82c108f27f80a44df52885e48ce2c9317b (plain) (tree)


















                                                        
#include <log.h>

int main() {
  logging::logger<> mlog;
  mlog.set_level(logging::kDbg0);

  INFO(&mlog, "Hallo %d", 42);
  WARN(&mlog, "Hallo %x", 0x1337);
  FAIL(&mlog, "Hallo %u", 666);
  DBG0(&mlog, "Hallo %p", (void*)0xf00df00d);

  {
    logging::logger<false> mlog;
    INFO(&mlog, "Hallo no time, %d", 42);
    WARN(&mlog, "Hallo no time, %x", 0x1337);
    FAIL(&mlog, "Hallo no time, %u", 666);
    DBG0(&mlog, "Hallo no time, %p", (void*)0xf00df00d);
  }
}