summaryrefslogtreecommitdiff
path: root/src/wasm/wat-parser.cpp
diff options
context:
space:
mode:
authorAlon Zakai <azakai@google.com>2023-09-06 15:54:44 -0700
committerGitHub <noreply@github.com>2023-09-06 15:54:44 -0700
commit90571051b3d6f89eab184df3d4dd716472a6cd7c (patch)
treef3ad6a4a3c96143813d69a5cd4dec567a3d65791 /src/wasm/wat-parser.cpp
parent126d4fab3e00f003a06dac23f96aa70cbb75aa67 (diff)
downloadbinaryen-90571051b3d6f89eab184df3d4dd716472a6cd7c.tar.gz
binaryen-90571051b3d6f89eab184df3d4dd716472a6cd7c.tar.bz2
binaryen-90571051b3d6f89eab184df3d4dd716472a6cd7c.zip
[NFC] Source maps: Simplify the code and add comments (#5912)
Almost entirely trivial, except for this part: - if (nextDebugLocation.availablePos == 0 && - nextDebugLocation.previousPos <= pos) { + if (nextDebugLocation.availablePos == 0) { return; I believe removing the extra check has no effect. Removing it does not change anything in the test suite, and logically, if we set availablePos to 0 then we definitely want to return here - we set it to 0 to indicate there is nothing left to read, which is what the code after it does. As a result, we can remove the previousPos field entirely.
Diffstat (limited to 'src/wasm/wat-parser.cpp')
0 files changed, 0 insertions, 0 deletions