diff options
author | Alon Zakai <azakai@google.com> | 2021-02-18 22:32:34 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-18 14:32:34 -0800 |
commit | ad0c8b4fd3808755fc071d43ebaa582a46d74922 (patch) | |
tree | e0b7934fdd754e8de1572b7eb4f68b361133b9ea /test/passes/dwarf_with_exceptions.cpp | |
parent | ec2aa7e870ef4d9926e35c5f4bfc7cdbabe2441a (diff) | |
download | binaryen-ad0c8b4fd3808755fc071d43ebaa582a46d74922.tar.gz binaryen-ad0c8b4fd3808755fc071d43ebaa582a46d74922.tar.bz2 binaryen-ad0c8b4fd3808755fc071d43ebaa582a46d74922.zip |
[Wasm Exceptions] Fix RemoveUnusedNames on Try (#3583)
The delegate field of Try was not being scanned, so we could
remove a name that was used only by a delegate.
The bug was because visitTry overrides the generic visitor
visitExpression. So we need to call it manually. Sadly the code here
was pretty old (I probably wrote it back in 2015 or so) and it was
misleading, as it had unnecessary calls from the generic visitor
to visitBlock, visitLoop, which are not needed. This PR removes
them which is shorter and cleaner.
Also, we must handle the case of the delegate field being unset,
so check name.is().
Diffstat (limited to 'test/passes/dwarf_with_exceptions.cpp')
0 files changed, 0 insertions, 0 deletions