fixed dijkstra memleak
new dijkstra interfaces and abort options refactored all files accordingly enable logging via compile-time defines
This commit is contained in:
16
misc/Debug.h
16
misc/Debug.h
@@ -9,12 +9,12 @@
|
||||
/** quick and dirty workaround */
|
||||
static decltype(Time::tick()) LogLastTick;
|
||||
|
||||
#ifdef WITH_DEBUG_LOG
|
||||
|
||||
class Log {
|
||||
|
||||
public:
|
||||
|
||||
|
||||
|
||||
static void add(const char* comp, const std::string what, const bool nl = true) {
|
||||
addComp(comp);
|
||||
std::cout << what;
|
||||
@@ -50,4 +50,16 @@ private:
|
||||
|
||||
};
|
||||
|
||||
#else
|
||||
|
||||
class Log {
|
||||
public:
|
||||
static void add(const char* comp, const std::string what, const bool nl = true) { (void)comp; (void) what; (void) nl; }
|
||||
static void add(const std::string& component, const std::string what, const bool nl = true) { (void)component; (void) what; (void) nl; }
|
||||
static void tick() {;}
|
||||
static void tock() {;}
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#endif // DEBUG_H
|
||||
|
||||
Reference in New Issue
Block a user