diff options
author | Ben Smith <binji@chromium.org> | 2016-04-14 19:03:10 -0700 |
---|---|---|
committer | Ben Smith <binji@chromium.org> | 2016-04-15 00:48:21 -0700 |
commit | 7c1ebc333ff50a7b8c0a5e6469ce518c9a3d47bd (patch) | |
tree | 3774a4ffddb67bba0eece9e2a064d294322cf8af /src/wasm-parser-lexer-shared.h | |
parent | 09b3e6839f60e9f43836da4e98ae02d90381ac18 (diff) | |
download | wabt-7c1ebc333ff50a7b8c0a5e6469ce518c9a3d47bd.tar.gz wabt-7c1ebc333ff50a7b8c0a5e6469ce518c9a3d47bd.tar.bz2 wabt-7c1ebc333ff50a7b8c0a5e6469ce518c9a3d47bd.zip |
move parser error printing into callback
Also the AST checker.
Diffstat (limited to 'src/wasm-parser-lexer-shared.h')
-rw-r--r-- | src/wasm-parser-lexer-shared.h | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/wasm-parser-lexer-shared.h b/src/wasm-parser-lexer-shared.h index 12b0f885..3acd1222 100644 --- a/src/wasm-parser-lexer-shared.h +++ b/src/wasm-parser-lexer-shared.h @@ -71,6 +71,7 @@ typedef union WasmToken { typedef struct WasmParser { struct WasmAllocator* allocator; WasmScript script; + WasmSourceErrorHandler* error_handler; int errors; } WasmParser; @@ -87,11 +88,11 @@ void wasm_parser_error(struct WasmLocation*, struct WasmParser*, const char*, ...); -void wasm_vfprint_error(FILE*, - const struct WasmLocation*, - WasmLexer, - const char*, - va_list); +void wasm_format_error(WasmSourceErrorHandler*, + const struct WasmLocation*, + WasmLexer, + const char* format, + va_list); WASM_EXTERN_C_END #endif /* WASM_PARSER_LEXER_SHARED_H_ */ |