FreeBASIC  0.91.0
fb_error.h
Go to the documentation of this file.
1 typedef enum _FB_RTERROR {
21 } FB_RTERROR;
22 
23 typedef void (*FB_ERRHANDLER) (void);
24 
25 typedef struct _FB_ERRORCTX {
27  int err_num;
28  int line_num;
29  const char *mod_name;
30  const char *fun_name;
31  void *res_lbl;
32  void *resnxt_lbl;
33 } FB_ERRORCTX;
34 
35 #define FB_ERRMSG_SIZE 1024
36 extern char __fb_errmsg[FB_ERRMSG_SIZE];
37 
38 FBCALL void fb_Assert ( char *filename, int linenum, char *funcname, char *expression );
39 FBCALL void fb_AssertWarn ( char *filename, int linenum, char *funcname, char *expression );
40 FBCALL void fb_AssertW ( char *filename, int linenum, char *funcname, FB_WCHAR *expression );
41 FBCALL void fb_AssertWarnW ( char *filename, int linenum, char *funcname, FB_WCHAR *expression );
42  FB_ERRHANDLER fb_ErrorThrowEx ( int errnum, int linenum, const char *fname,
43  void *res_label, void *resnext_label );
44  FB_ERRHANDLER fb_ErrorThrowAt ( int line_num, const char *mod_name,
45  void *res_label, void *resnext_label );
47 FBCALL int fb_ErrorGetNum ( void );
48 FBCALL int fb_ErrorSetNum ( int errnum );
49  void *fb_ErrorResume ( void );
50  void *fb_ErrorResumeNext ( void );
51 FBCALL int fb_ErrorGetLineNum ( void );
52 FBCALL const char *fb_ErrorGetModName ( void );
53 FBCALL const char *fb_ErrorSetModName ( const char *mod_name );
54 FBCALL const char *fb_ErrorGetFuncName( void );
55 FBCALL const char *fb_ErrorSetFuncName( const char *fun_name );