Skip to content

Commit 17b6160

Browse files
[gardening] Remove unused method replaceValue(..., ...)
1 parent 1475ab6 commit 17b6160

File tree

1 file changed

+0
-14
lines changed

1 file changed

+0
-14
lines changed

lib/SILOptimizer/Mandatory/AddressLowering.cpp

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -92,20 +92,6 @@ class ValueStorageMap {
9292

9393
return valueVector.back().second;
9494
}
95-
96-
// Replace entry for `oldValue` with an entry for `newValue` preserving the
97-
// the mapped ValueStorage.
98-
void replaceValue(SILValue oldValue, SILValue newValue) {
99-
auto hashIter = valueHashMap.find(oldValue);
100-
assert(hashIter != valueHashMap.end() && "Missing SILValue");
101-
unsigned idx = hashIter->second;
102-
valueHashMap.erase(hashIter);
103-
104-
valueVector[idx].first = newValue;
105-
106-
auto hashResult = valueHashMap.insert(std::make_pair(newValue, idx));
107-
assert(hashResult.second && "SILValue already mapped");
108-
}
10995
};
11096
} // end anonymous namespace
11197

0 commit comments

Comments
 (0)