TransformUtils: Remove implicit ilist iterator conversions, NFC
[oota-llvm.git] / lib / Transforms / Utils / CtorUtils.cpp
index dc95089cd2cadab64b95da25e9d90f246f904792..b56ff684e8a88a13e64cb0b889d4307b30be7599 100644 (file)
@@ -50,7 +50,7 @@ void removeGlobalCtors(GlobalVariable *GCL, const BitVector &CtorsToRemove) {
   GlobalVariable *NGV =
       new GlobalVariable(CA->getType(), GCL->isConstant(), GCL->getLinkage(),
                          CA, "", GCL->getThreadLocalMode());
-  GCL->getParent()->getGlobalList().insert(GCL, NGV);
+  GCL->getParent()->getGlobalList().insert(GCL->getIterator(), NGV);
   NGV->takeName(GCL);
 
   // Nuke the old list, replacing any uses with the new one.