void ConstantArray::refineAbstractType(const DerivedType *OldTy,
const Type *NewTy) {
Value::refineAbstractType(OldTy, NewTy);
+ if (OldTy == NewTy) return;
// Make everyone now use a constant of the new type...
std::vector<Constant*> C;
void ConstantStruct::refineAbstractType(const DerivedType *OldTy,
const Type *NewTy) {
Value::refineAbstractType(OldTy, NewTy);
+ if (OldTy == NewTy) return;
// Make everyone now use a constant of the new type...
std::vector<Constant*> C;
void ConstantPointerNull::refineAbstractType(const DerivedType *OldTy,
const Type *NewTy) {
Value::refineAbstractType(OldTy, NewTy);
+ if (OldTy == NewTy) return;
// Make everyone now use a constant of the new type...
if (NewTy != OldTy) {
void ConstantExpr::refineAbstractType(const DerivedType *OldTy,
const Type *NewTy) {
Value::refineAbstractType(OldTy, NewTy);
+ if (OldTy == NewTy) return;
// FIXME: These need to use a lower-level implementation method, because the
// ::get methods intuit the type of the result based on the types of the