summaryrefslogtreecommitdiff
path: root/src/wasm-io.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/wasm-io.h')
-rw-r--r--src/wasm-io.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/wasm-io.h b/src/wasm-io.h
index ae66c3932..e5cad9a23 100644
--- a/src/wasm-io.h
+++ b/src/wasm-io.h
@@ -22,6 +22,7 @@
#define wasm_wasm_io_h
#include "parsing.h"
+#include "pass.h"
#include "support/file.h"
#include "wasm.h"
@@ -85,6 +86,8 @@ private:
};
class ModuleWriter : public ModuleIOBase {
+ const PassOptions& options;
+
bool binary = true;
// TODO: Remove `emitModuleName`. See the comment in wasm-binary.h
@@ -97,7 +100,9 @@ class ModuleWriter : public ModuleIOBase {
public:
// Writing defaults to not storing the names section. Storing it is a user-
// observable fact that must be opted into.
- ModuleWriter() { setDebugInfo(false); }
+ ModuleWriter(const PassOptions& options) : options(options) {
+ setDebugInfo(false);
+ }
void setBinary(bool binary_) { binary = binary_; }
void setSymbolMap(std::string symbolMap_) { symbolMap = symbolMap_; }