Back out r166591, not sure why this made it through since I cancelled the command...
[oota-llvm.git] / lib / VMCore / Constants.cpp
index b96257936df880144dd7495f15f8c2f2dd1f70dd..a4e21e16b3fcfb31f2e9774656738f34cf4eb0f6 100644 (file)
@@ -1673,7 +1673,7 @@ Constant *ConstantExpr::getAlignOf(Type* Ty) {
   // Note that a non-inbounds gep is used, as null isn't within any object.
   Type *AligningTy = 
     StructType::get(Type::getInt1Ty(Ty->getContext()), Ty, NULL);
-  Constant *NullPtr = Constant::getNullValue(AligningTy->getPointerTo(Ty));
+  Constant *NullPtr = Constant::getNullValue(AligningTy->getPointerTo());
   Constant *Zero = ConstantInt::get(Type::getInt64Ty(Ty->getContext()), 0);
   Constant *One = ConstantInt::get(Type::getInt32Ty(Ty->getContext()), 1);
   Constant *Indices[2] = { Zero, One };