diff options
| -rw-r--r-- | lib.c | 2 | ||||
| -rw-r--r-- | lib.h | 9 |
2 files changed, 9 insertions, 2 deletions
@@ -191,6 +191,7 @@ void expression_error(struct expression *expr, const char *fmt, ...) expr->ctype = &bad_ctype; } +NORETURN_ATTR void error_die(struct position pos, const char * fmt, ...) { va_list args; @@ -200,6 +201,7 @@ void error_die(struct position pos, const char * fmt, ...) exit(1); } +NORETURN_ATTR void die(const char *fmt, ...) { va_list args; @@ -91,11 +91,16 @@ struct token *expect(struct token *, int, const char *); #define NORETURN_ATTR #define SENTINEL_ATTR #endif -extern void die(const char *, ...) FORMAT_ATTR(1) NORETURN_ATTR; + +FORMAT_ATTR(1) NORETURN_ATTR +extern void die(const char *, ...); + +FORMAT_ATTR(2) NORETURN_ATTR +extern void error_die(struct position, const char *, ...); + extern void info(struct position, const char *, ...) FORMAT_ATTR(2); extern void warning(struct position, const char *, ...) FORMAT_ATTR(2); extern void sparse_error(struct position, const char *, ...) FORMAT_ATTR(2); -extern void error_die(struct position, const char *, ...) FORMAT_ATTR(2) NORETURN_ATTR; extern void expression_error(struct expression *, const char *, ...) FORMAT_ATTR(2); #define ERROR_CURR_PHASE (1 << 0) |
