Mercurial > projects > ldc
view gen/logger.h @ 120:5ce8ab11e75a trunk
[svn r124] Fixed another D vararg + return in ptr bug.
Fixed some nested function calls failed to resolve the context ptr.
author | lindquist |
---|---|
date | Mon, 26 Nov 2007 07:26:21 +0100 |
parents | 61615fa85940 |
children | 5825d48b27d1 |
line wrap: on
line source
#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(); void attention(const char* fmt, ...); struct LoggerScope { LoggerScope() { Logger::indent(); } ~LoggerScope() { Logger::undent(); } }; } #define LOG_SCOPE Logger::LoggerScope _logscope; #endif