From 9bde26331ba0f8da5165a8aaf192d9bb2bb72648 Mon Sep 17 00:00:00 2001 From: Alex Beregszaszi Date: Thu, 18 Jan 2018 18:53:48 +0000 Subject: Make input a const reference to WasmBinaryBuilder (#1367) --- src/wasm-binary.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/wasm-binary.h b/src/wasm-binary.h index 813404895..e5bfd9f2d 100644 --- a/src/wasm-binary.h +++ b/src/wasm-binary.h @@ -802,7 +802,7 @@ public: class WasmBinaryBuilder { Module& wasm; MixedArena& allocator; - std::vector& input; + const std::vector& input; bool debug; std::istream* sourceMap; std::pair nextDebugLocation; @@ -814,7 +814,7 @@ class WasmBinaryBuilder { std::set seenSections; public: - WasmBinaryBuilder(Module& wasm, std::vector& input, bool debug) : wasm(wasm), allocator(wasm.allocator), input(input), debug(debug), sourceMap(nullptr), nextDebugLocation(0, { 0, 0, 0 }), useDebugLocation(false) {} + WasmBinaryBuilder(Module& wasm, const std::vector& input, bool debug) : wasm(wasm), allocator(wasm.allocator), input(input), debug(debug), sourceMap(nullptr), nextDebugLocation(0, { 0, 0, 0 }), useDebugLocation(false) {} void read(); void readUserSection(size_t payloadLen); -- cgit v1.2.3