Don't force things to be Value * when they're not.
authorDavid Greene <greened@obbligato.org>
Wed, 29 Oct 2008 00:30:54 +0000 (00:30 +0000)
committerDavid Greene <greened@obbligato.org>
Wed, 29 Oct 2008 00:30:54 +0000 (00:30 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58354 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Instructions.h

index 22787570112600b222097589018d24dde51f1afa..6ee18313a221969afe8cc1726eb16b55e0847df6 100644 (file)
@@ -420,7 +420,7 @@ class GetElementPtrInst : public Instruction {
 
     if (NumIdx > 0)
       // This requires that the iterator points to contiguous memory.
-      return getIndexedType(Ptr, (Value *const *)&*IdxBegin, NumIdx);
+      return getIndexedType(Ptr, &*IdxBegin, NumIdx);
     else
       return getIndexedType(Ptr, (Value *const*)0, NumIdx);
   }