summaryrefslogtreecommitdiff
path: root/src/wast-parser.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/wast-parser.h')
-rw-r--r--src/wast-parser.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/wast-parser.h b/src/wast-parser.h
index 8251df9d..9a5d99a1 100644
--- a/src/wast-parser.h
+++ b/src/wast-parser.h
@@ -20,6 +20,7 @@
#include <array>
#include "circular-array.h"
+#include "feature.h"
#include "ir.h"
#include "intrusive-list.h"
#include "wast-lexer.h"
@@ -29,7 +30,9 @@ namespace wabt {
class ErrorHandler;
struct WastParseOptions {
- bool allow_future_exceptions = false;
+ WastParseOptions(const Features& features) : features(features) {}
+
+ Features features;
bool debug_parsing = false;
};
@@ -43,7 +46,7 @@ class WastParser {
Result ParseScript(Script*);
private:
- void ErrorUnlessExceptionsAllowed();
+ void ErrorUnlessOpcodeEnabled(const Token&);
// Print an error message listing the expected tokens, as well as an example
// of expected input.