master repository for XO: cooperating set of C++ libraries for deterministic simulation
  • C++ 87.5%
  • C 6.2%
  • CMake 3.4%
  • Nix 1%
  • Objective-C++ 0.6%
  • Other 1.2%
Find a file
2023-09-11 16:10:50 -04:00
example initial implementation + example + cmake "build" 2023-09-11 16:09:26 -04:00
include/nestlog initial implementation + example + cmake "build" 2023-09-11 16:09:26 -04:00
CMakeLists.txt initial implementation + example + cmake "build" 2023-09-11 16:09:26 -04:00
README.md doc: README.md example 2023-09-11 16:10:50 -04:00

nestlog -- logging with automatic indenting according to call graph

Nestlog is a lightweight header-only library for console logging.

Examples

```
/* examples/ex1/ex1.cpp */

#include "nestlog/scope.hpp"

using namespace xo;

void A(int x) {
    XO_SCOPE(log)  // i.e. xo::scope log("A");

    log(":x ", x);
}

int
main(int argc, char ** argv) {
    A(66);
}
```

output: +A :x 66 -A