Add an assertion so that we don't accidentally build constant arrays of 
VLAs.

llvm-svn: 72587
diff --git a/clang/lib/AST/ASTContext.cpp b/clang/lib/AST/ASTContext.cpp
index b230edb..00eaa36 100644
--- a/clang/lib/AST/ASTContext.cpp
+++ b/clang/lib/AST/ASTContext.cpp
@@ -1063,6 +1063,9 @@
                                           const llvm::APInt &ArySizeIn,
                                           ArrayType::ArraySizeModifier ASM,
                                           unsigned EltTypeQuals) {
+  assert((EltTy->isDependentType() || EltTy->isConstantSizeType()) &&
+         "Constant array of VLAs is illegal!");
+
   // Convert the array size into a canonical width matching the pointer size for
   // the target.
   llvm::APInt ArySize(ArySizeIn);