debug.h - ctags-5.8
Data types defined
Macros defined
Source code
#ifndef _DEBUG_H
#define _DEBUG_H
#include "general.h"
#ifdef DEBUG
# include <assert.h>
#endif
#include "entry.h"
#ifdef DEBUG
# define debug(level) ((Option.debugLevel & (long)(level)) != 0)
# define DebugStatement(x) x
# define PrintStatus(x) if (debug(DEBUG_STATUS)) printf x;
# define Assert(c) assert(c)
#else
# define DebugStatement(x)
# define PrintStatus(x)
# define Assert(c)
# ifndef NDEBUG
# define NDEBUG
# endif
#endif
enum eDebugLevels {
DEBUG_READ = 0x01, DEBUG_PARSE = 0x02, DEBUG_STATUS = 0x04, DEBUG_OPTION = 0x08, DEBUG_CPP = 0x10, DEBUG_RAW = 0x20 };
extern void lineBreak (void);
extern void debugPrintf (const enum eDebugLevels level, const char *const format, ...) __printf__ (2, 3);
extern void debugPutc (const int level, const int c);
extern void debugParseNest (const boolean increase, const unsigned int level);
extern void debugCppNest (const boolean begin, const unsigned int level);
extern void debugCppIgnore (const boolean ignore);
extern void debugEntry (const tagEntryInfo *const tag);
#endif