diff --git a/clang/lib/CodeGen/CGExprConstant.cpp b/clang/lib/CodeGen/CGExprConstant.cpp index 5b3631087f45dd..b0a37531dfe132 100644 --- a/clang/lib/CodeGen/CGExprConstant.cpp +++ b/clang/lib/CodeGen/CGExprConstant.cpp @@ -2141,15 +2141,6 @@ llvm::Constant *ConstantEmitter::tryEmitPrivate(const APValue &Value, Elts.push_back(C); } - // This means that the array type is probably "IncompleteType" or some - // type that is not ConstantArray. - if (!Filler && !NumInitElts) { - CommonElementType = CGM.getTypes().ConvertType(ArrayTy->getElementType()); - llvm::ArrayType *AType = - llvm::ArrayType::get(CommonElementType, NumElements); - return llvm::ConstantAggregateZero::get(AType); - } - llvm::ArrayType *Desired = cast(CGM.getTypes().ConvertType(DestType)); return EmitArrayConstant(CGM, Desired, CommonElementType, NumElements, Elts,