[llvm] r304349 - Try to fix buildbots
Matthias Braun via llvm-commits
llvm-commits at lists.llvm.org
Wed May 31 14:25:04 PDT 2017
Author: matze
Date: Wed May 31 16:25:03 2017
New Revision: 304349
URL: http://llvm.org/viewvc/llvm-project?rev=304349&view=rev
Log:
Try to fix buildbots
It seems not all of our bots have a std::vector::erase() taking a
const_iterator (even though that seems to be part of C++11) attempt to
workaround.
Modified:
llvm/trunk/lib/CodeGen/MachineBasicBlock.cpp
Modified: llvm/trunk/lib/CodeGen/MachineBasicBlock.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/MachineBasicBlock.cpp?rev=304349&r1=304348&r2=304349&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/MachineBasicBlock.cpp (original)
+++ llvm/trunk/lib/CodeGen/MachineBasicBlock.cpp Wed May 31 16:25:03 2017
@@ -352,7 +352,9 @@ void MachineBasicBlock::removeLiveIn(MCP
MachineBasicBlock::livein_iterator
MachineBasicBlock::removeLiveIn(MachineBasicBlock::livein_iterator I) {
- return LiveIns.erase(I);
+ // Get non-const version of iterator.
+ LiveInVector::iterator LI = LiveIns.begin() + (I - LiveIns.begin());
+ return LiveIns.erase(LI);
}
bool MachineBasicBlock::isLiveIn(MCPhysReg Reg, LaneBitmask LaneMask) const {
More information about the llvm-commits
mailing list