diff options
author | Yury Delendik <ydelendik@mozilla.com> | 2017-06-01 14:53:42 -0500 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2017-06-01 12:53:42 -0700 |
commit | 0dc07eaa7db35cf65edbbccebe5c89b995613745 (patch) | |
tree | 0718148a976b882c826c09189a3e779be311c69e /src/wasm.h | |
parent | fcbe14a64d082117d7aab9bbf479e941964cd0de (diff) | |
download | binaryen-0dc07eaa7db35cf65edbbccebe5c89b995613745.tar.gz binaryen-0dc07eaa7db35cf65edbbccebe5c89b995613745.tar.bz2 binaryen-0dc07eaa7db35cf65edbbccebe5c89b995613745.zip |
Exporting/importing debug location information from .wast/.asm.js/.s formats (#1017)
* Extends wasm-as, wasm-dis and s2wasm to consume debug locations.
* Exports source map from asm2wasm
Diffstat (limited to 'src/wasm.h')
-rw-r--r-- | src/wasm.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/wasm.h b/src/wasm.h index 3caab9dbc..dba08d92e 100644 --- a/src/wasm.h +++ b/src/wasm.h @@ -527,7 +527,9 @@ public: std::map<Name, Index> localIndices; struct DebugLocation { - uint32_t fileIndex, lineNumber; + uint32_t fileIndex, lineNumber, columnNumber; + bool operator==(const DebugLocation& other) const { return fileIndex == other.fileIndex && lineNumber == other.lineNumber && columnNumber == other.columnNumber; } + bool operator!=(const DebugLocation& other) const { return !(*this == other); } }; std::unordered_map<Expression*, DebugLocation> debugLocations; |