Vector cast handling differently in C++

Hi,

I was wondering what is the reasoning behind the C and C++ difference in handling vector casts. Specifically:

void CastOperation::CheckCStyleCast()
...
  if (DestType->isExtVectorType()) {
    SrcExpr = Self.CheckExtVectorCast(OpRange, DestType, SrcExpr.get(), Kind);
    return;
  }

  if (const VectorType *DestVecTy = DestType->getAs<VectorType>()) {
    if (DestVecTy->getVectorKind() == VectorType::AltiVecVector &&
          (SrcType->isIntegerType() || SrcType->isFloatingType())) {
      Kind = CK_VectorSplat;
      SrcExpr = Self.prepareVectorSplat(DestType, SrcExpr.get());
    } else if (Self.CheckVectorCast(OpRange, DestType, SrcType, Kind)) {
      SrcExpr = ExprError();
    }
    return;
  }

  if (SrcType->isVectorType()) {
    if (Self.CheckVectorCast(OpRange, SrcType, DestType, Kind))
      SrcExpr = ExprError();
    return;
  }

While in the c++ cast handling, only AltiVecVector casts are handled:

void CastOperation::CheckCXXCStyleCast(bool FunctionalStyle,
                                       bool ListInitialization)
...
  // AltiVec vector initialization with a single literal.
  if (const VectorType *vecTy = DestType->getAs<VectorType>())
    if (vecTy->getVectorKind() == VectorType::AltiVecVector
        && (SrcExpr.get()->getType()->isIntegerType()
            || SrcExpr.get()->getType()->isFloatingType())) {
      Kind = CK_VectorSplat;
      SrcExpr = Self.prepareVectorSplat(DestType, SrcExpr.get());
      return;
    }

Where is C++ supposed to handle the vector casting? Seems like only the altivec handling is consistent between C and C++? Am I missing a different place that handles Vector and ExtVector casts?

I have some changes for CheckVectorCast function which I need to also apply in C++.

Thanks,

Gal