![]() |
Purple
0.1
Standard Language Specification
|
Warnings and fatal error handling. More...
#include <stdarg.h>#include <stdlib.h>#include "data.h"#include "utils/arguments.h"#include "utils/logging.h"
Functions | |
| void | fatal (ReturnCode rc, const char *fmt,...) |
| Raises a fatal error that will exit the compiler. More... | |
| void | syntax_error (char *fn, int line_number, int char_number, const char *fmt,...) |
| Raises a fatal syntax error. More... | |
| void | identifier_error (char *fn, int line_number, int char_number, const char *fmt,...) |
| Raises a fatal identifier error. More... | |
| void | purple_log (LogLevel level, const char *fmt,...) |
| Raises a non-fatal logging statement. More... | |
Warnings and fatal error handling.
| void fatal | ( | ReturnCode | rc, |
| const char * | fmt, | ||
| ... | |||
| ) |
Raises a fatal error that will exit the compiler.
| rc | Return code to exit with |
| fmt | Format string for printed error |
| ... | Varargs for printed error |
| void identifier_error | ( | char * | fn, |
| int | line_number, | ||
| int | char_number, | ||
| const char * | fmt, | ||
| ... | |||
| ) |
Raises a fatal identifier error.
| fn | Filename in which identifier error occurs |
| line_number | Line number on which identifier error occurs |
| char_number | Character numbre on which syntax error occurs |
| fmt | Format string for details printed before fatal error |
| ... | Varargs for details printed before fatal error |
| void purple_log | ( | LogLevel | level, |
| const char * | fmt, | ||
| ... | |||
| ) |
Raises a non-fatal logging statement.
| level | Severity of statement |
| fmt | Format string for printed statement |
| ... | Varargs for printed statement |
| void syntax_error | ( | char * | fn, |
| int | line_number, | ||
| int | char_number, | ||
| const char * | fmt, | ||
| ... | |||
| ) |
Raises a fatal syntax error.
| fn | Filename in which syntax error occurs |
| line_number | Line number on which syntax error occurs |
| char_number | Character numbre on which syntax error occurs |
| fmt | Format string for details printed before fatal error |
| ... | Varargs for details printed before fatal error |