Files
ldc/gen/logger.h
Tomas Lindquist Olsen 52a6e71703 [svn r42] Disabled the extensive logging by default. Use the -vv flag to get it back.
Fiddled a bit the the testing system.
Added a very simple SDL graphics demo.
2007-10-10 06:16:48 +02:00

35 lines
544 B
C++

#ifndef _llvmd_gen_logger_h_
#define _llvmd_gen_logger_h_
#include <iostream>
namespace Logger
{
void indent();
void undent();
std::ostream& cout();
void println(const char* fmt, ...);
void print(const char* fmt, ...);
void enable();
void disable();
struct LoggerScope
{
LoggerScope()
{
Logger::indent();
}
~LoggerScope()
{
Logger::undent();
}
};
}
#define LOG_SCOPE Logger::LoggerScope _logscope;
#endif