diff options
author | Ben Smith <binjimin@gmail.com> | 2019-02-12 14:41:34 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-02-12 14:41:34 -0800 |
commit | e448ac7cbd74f7a048b1de15ce1a2716340a57c8 (patch) | |
tree | 2cdbf9372eabfb2584d26279beee84062036c348 /src/binary-reader.h | |
parent | 35ee613d4f8e65e730aaa6d519ee39ce581d4f24 (diff) | |
download | wabt-e448ac7cbd74f7a048b1de15ce1a2716340a57c8.tar.gz wabt-e448ac7cbd74f7a048b1de15ce1a2716340a57c8.tar.bz2 wabt-e448ac7cbd74f7a048b1de15ce1a2716340a57c8.zip |
Parse updated event text and binary format (#1014)
An event has a type-section index, like a function definition. The
current proposal doesn't specify the text format, so I assumed that it
would match the format of the other sections that reference function
types. This means that the following declaration styles are allowed:
```
(type $t (func (param i32)))
(event $e1 (type $t))
(event $e2 (param f32))
```
Diffstat (limited to 'src/binary-reader.h')
-rw-r--r-- | src/binary-reader.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/binary-reader.h b/src/binary-reader.h index fb13819b..46424977 100644 --- a/src/binary-reader.h +++ b/src/binary-reader.h @@ -116,10 +116,10 @@ class BinaryReaderDelegate { Type type, bool mutable_) = 0; virtual Result OnImportEvent(Index import_index, - string_view module_name, - string_view field_name, - Index event_index, - TypeVector& sig) = 0; + string_view module_name, + string_view field_name, + Index event_index, + Index sig_index) = 0; virtual Result EndImportSection() = 0; /* Function section */ @@ -373,7 +373,7 @@ class BinaryReaderDelegate { /* Event section */ virtual Result BeginEventSection(Offset size) = 0; virtual Result OnEventCount(Index count) = 0; - virtual Result OnEventType(Index index, TypeVector& sig) = 0; + virtual Result OnEventType(Index index, Index sig_index) = 0; virtual Result EndEventSection() = 0; /* InitExpr - used by elem, data and global sections; these functions are |