Lephisto/src/log.h
2013-01-30 22:22:30 +00:00

15 lines
323 B
C

#pragma once
#include <stdio.h>
#define LOG(str, args...)(fprintf(stdout, str"\n", ## args))
#define WARN(str, args...)(fprintf(stderr, "[%d] "str"\n", 0, ## args))
#ifdef DEBUG
# undef DEBUG
# define DEBUG(str, args...) LOG(str, ## args)
# define DEBUGGING
#else
# define DEBUG(str, args...) do {;} while(0)
#endif