if (Args[0]->getType()->isIncompleteType())
return false;
+ // Make sure the first argument is not an abstract type.
+ CXXRecordDecl *RD = Args[0]->getType()->getAsCXXRecordDecl();
+ if (RD && RD->isAbstract())
+ return false;
+
SmallVector<OpaqueValueExpr, 2> OpaqueArgExprs;
SmallVector<Expr *, 2> ArgExprs;
ArgExprs.reserve(Args.size() - 1);
{ int arr[T(__is_constructible(NonPOD, int))]; }
{ int arr[F(__is_nothrow_constructible(NonPOD, int))]; }
+
+ // PR19178
+ { int arr[F(__is_constructible(Abstract))]; }
+ { int arr[F(__is_nothrow_constructible(Abstract))]; }
}
// Instantiation of __is_trivially_constructible
{ int arr[F((is_trivially_constructible<int, int*>::value))]; }
{ int arr[F((is_trivially_constructible<NonTrivialDefault>::value))]; }
{ int arr[F((is_trivially_constructible<ThreeArgCtor, int*, char*, int&>::value))]; }
+ { int arr[F((is_trivially_constructible<Abstract>::value))]; } // PR19178
}
void array_rank() {