mirror of
https://github.com/Unidata/netcdf-c.git
synced 2024-11-21 03:13:42 +08:00
28 lines
658 B
C
28 lines
658 B
C
#ifndef AST_DEBUG_H
|
|
#define AST_DEBUG_H
|
|
|
|
#define ASTDEBUG
|
|
|
|
#ifdef ASTDEBUG
|
|
extern int ast_catch(int);
|
|
extern void ast_breakpoint(int code);
|
|
#endif
|
|
|
|
/* Provide an error catcher */
|
|
#ifdef ASTDEBUG
|
|
#define ACATCH(status) (ast_catch(status))
|
|
#define ATHROW(status,go) {ast_catch(status);goto go;}
|
|
#define AERR(status,err,go) {status=err;ast_catch(status);goto go;}
|
|
#else
|
|
#define ACATCH(status) (status);
|
|
#define ATHROWCHK(status) ACATCH(status)
|
|
#define ATHROW(status,go) {goto go;}
|
|
#define AERR(status,err,go) {goto go;}
|
|
#endif
|
|
|
|
extern unsigned char* xbytes(ast_runtime*);
|
|
extern size_t xpos(ast_runtime* rt);
|
|
|
|
|
|
#endif /*AST_DEBUG_H*/
|