diff options
Diffstat (limited to 'lib/nimbase.h')
-rwxr-xr-x | lib/nimbase.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/nimbase.h b/lib/nimbase.h index 7fb70a60c..4735cbb4f 100755 --- a/lib/nimbase.h +++ b/lib/nimbase.h @@ -436,6 +436,17 @@ struct TFrame { NI len; }; +#define nimfr(proc, file) \ + volatile TFrame F; \ + F.procname = proc; F.filename = file; F.line = 0; F.len = 0; nimFrame(&F); + +#define nimfrs(proc, file, slots) \ + volatile struct {TFrame* prev;NCSTRING procname;NI line;NCSTRING filename; NI len; TVarSlot s[slots];} F; \ + F.procname = proc; F.filename = file; F.line = 0; F.len = slots; nimFrame((TFrame*)&F); + +#define nimln(n, file) \ + F.line = n; F.filename = file; + #define NIM_POSIX_INIT __attribute__((constructor)) #if defined(_MSCVER) && defined(__i386__) |