diff options
author | Mattias Andrée <maandree@operamail.com> | 2014-12-13 16:07:36 +0100 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2014-12-13 16:07:36 +0100 |
commit | fc0cdca948f16bcf7590e057878fca1d4ce1ed6e (patch) | |
tree | 85702bcba4e49ede4dc8984fa0ca44ac83bc84d7 /src/mds-kbdc/compile-layout.c | |
parent | mds-kbdc: compile-layout: use the call-stack (diff) | |
download | mds-fc0cdca948f16bcf7590e057878fca1d4ce1ed6e.tar.gz mds-fc0cdca948f16bcf7590e057878fca1d4ce1ed6e.tar.bz2 mds-fc0cdca948f16bcf7590e057878fca1d4ce1ed6e.tar.xz |
mds-kbdc: dump call-stack
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to '')
-rw-r--r-- | src/mds-kbdc/compile-layout.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/mds-kbdc/compile-layout.c b/src/mds-kbdc/compile-layout.c index b2cd5e0..89f507f 100644 --- a/src/mds-kbdc/compile-layout.c +++ b/src/mds-kbdc/compile-layout.c @@ -17,7 +17,7 @@ */ #include "compile-layout.h" /* XXX fix so that for-loops do not generate the same errors/warnings in all iterations [loopy_error]. */ -/* XXX add pragma support */ +/* XXX add pragma support: mark as shadowable, stop warnings, print variable value */ #include "call-stack.h" #include "builtin-functions.h" @@ -49,8 +49,13 @@ * @param ...:const char*, ... Error description format string and arguments * @scope error:mds_kbdc_parse_error_t* Variable where the new error will be stored */ -#define NEW_ERROR(NODE, SEVERITY, ...) \ - NEW_ERROR_WITH_INCLUDES(NODE, includes_ptr, SEVERITY, __VA_ARGS__) +#define NEW_ERROR(NODE, SEVERITY, ...) \ + do \ + { \ + NEW_ERROR_WITH_INCLUDES(NODE, includes_ptr, SEVERITY, __VA_ARGS__); \ + DUMP_CALL_STACK; \ + } \ + while (0) /** * Beginning of failure clause |