diff options
author | Thomas Lively <7121787+tlively@users.noreply.github.com> | 2020-01-07 10:16:10 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-01-07 10:16:10 -0800 |
commit | f73b40c7873dbd2dd46a962f3afe5b97a7fc8b0a (patch) | |
tree | 00cf4a6712fae15faad384c4c541100bdf012d5f /src/passes | |
parent | 85de1c127d7d05966b4589d33718bbb70b961c24 (diff) | |
download | binaryen-f73b40c7873dbd2dd46a962f3afe5b97a7fc8b0a.tar.gz binaryen-f73b40c7873dbd2dd46a962f3afe5b97a7fc8b0a.tar.bz2 binaryen-f73b40c7873dbd2dd46a962f3afe5b97a7fc8b0a.zip |
[NFC] Clean up unnecessary `template`s in calls 🧹🧹🧹 (#2394)
Diffstat (limited to 'src/passes')
-rw-r--r-- | src/passes/OptimizeAddedConstants.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/passes/OptimizeAddedConstants.cpp b/src/passes/OptimizeAddedConstants.cpp index 8a72a0cd0..a34d1b96d 100644 --- a/src/passes/OptimizeAddedConstants.cpp +++ b/src/passes/OptimizeAddedConstants.cpp @@ -143,7 +143,7 @@ private: // success, the returned offset can be added as a replacement for the // expression here. bool tryToOptimizeConstant(Expression* oneSide, Expression* otherSide) { - if (auto* c = oneSide->template dynCast<Const>()) { + if (auto* c = oneSide->dynCast<Const>()) { auto result = canOptimizeConstant(c->value); if (result.succeeded) { curr->offset = result.total; @@ -161,8 +161,8 @@ private: Expression* otherSide, LocalGet* ptr, LocalSet* set) { - if (auto* c = oneSide->template dynCast<Const>()) { - if (otherSide->template is<Const>()) { + if (auto* c = oneSide->dynCast<Const>()) { + if (otherSide->is<Const>()) { // Both sides are constant - this is not optimized code, ignore. return false; } @@ -191,7 +191,7 @@ private: // dominates the load, and it is ok to replace x with y + 10 there. Index index = -1; bool canReuseIndex = false; - if (auto* get = otherSide->template dynCast<LocalGet>()) { + if (auto* get = otherSide->dynCast<LocalGet>()) { if (localGraph->isSSA(get->index) && localGraph->isSSA(ptr->index)) { index = get->index; canReuseIndex = true; |