diff options
author | Sam Clegg <sbc@chromium.org> | 2016-12-14 17:44:37 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-12-14 17:44:37 -0800 |
commit | cdcdda11bbdf2d39340ec9bdb51e6af8e2cb268c (patch) | |
tree | f0b5609e4404b0d4d44d3091809edbd749a0b27f /src/binary-reader-ast.c | |
parent | 55293660eb9f01d50256cb272478e2ad86713c6b (diff) | |
download | wabt-cdcdda11bbdf2d39340ec9bdb51e6af8e2cb268c.tar.gz wabt-cdcdda11bbdf2d39340ec9bdb51e6af8e2cb268c.tar.bz2 wabt-cdcdda11bbdf2d39340ec9bdb51e6af8e2cb268c.zip |
Make some binary reading/writing utilities public (#245)
* Make some binary reading/writing utilities public
This is mostly a refactor to make some of the internal
binary reading/writing utilities public and available
to the wasm linker prototype that I'm working on.
Diffstat (limited to 'src/binary-reader-ast.c')
-rw-r--r-- | src/binary-reader-ast.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/binary-reader-ast.c b/src/binary-reader-ast.c index 01c092b1..e82b82c2 100644 --- a/src/binary-reader-ast.c +++ b/src/binary-reader-ast.c @@ -837,10 +837,11 @@ static WasmResult end_elem_segment_init_expr(uint32_t index, void* user_data) { return WASM_OK; } -static WasmResult on_elem_segment_function_index_count(uint32_t index, - uint32_t count, - void* user_data) { - Context* ctx = user_data; +static WasmResult on_elem_segment_function_index_count( + WasmBinaryReaderContext* context, + uint32_t index, + uint32_t count) { + Context* ctx = context->user_data; assert(index == ctx->module->elem_segments.size - 1); WasmElemSegment* segment = ctx->module->elem_segments.data[index]; wasm_reserve_vars(ctx->allocator, &segment->vars, count); |