summaryrefslogtreecommitdiff
path: root/BFS/support/utils.h
blob: ddb1e2c217cc8ada2e71d817b5389731f10d7f78 (plain)
1
2
3
4
5
6
7
8
9
10
11

#ifndef _UTILS_H_
#define _UTILS_H_

#define PRINT_ERROR(fmt, ...)       fprintf(stderr, "\033[0;31mERROR:\033[0m   " fmt "\n", ##__VA_ARGS__)
#define PRINT_WARNING(fmt, ...)     fprintf(stderr, "\033[0;35mWARNING:\033[0m " fmt "\n", ##__VA_ARGS__)
#define PRINT_INFO(cond, fmt, ...)  if(cond) printf("\033[0;32mINFO:\033[0m    " fmt "\n", ##__VA_ARGS__);
#define PRINT(fmt, ...)             printf(fmt "\n", ##__VA_ARGS__)

#endif