Reverted r93198; done without reading relevant PR.

llvm-svn: 93205
This commit is contained in:
David Chisnall 2010-01-11 23:08:08 +00:00
parent 42b07e9600
commit a354f12be2
1 changed files with 2 additions and 4 deletions

View File

@ -651,10 +651,8 @@ QualType Sema::BuildArrayType(QualType T, ArrayType::ArraySizeModifier ASM,
} }
T = Context.getConstantArrayType(T, ConstVal, ASM, Quals); T = Context.getConstantArrayType(T, ConstVal, ASM, Quals);
} }
// If this is not C99 or C++ with GNU extenisons, extwarn about VLA's and C99 // If this is not C99, extwarn about VLA's and C99 array size modifiers.
// array size modifiers. if (!getLangOptions().C99) {
if (!getLangOptions().C99 &&
!(getLangOptions().CPlusPlus && getLangOptions().GNUMode)) {
if (ArraySize && !ArraySize->isTypeDependent() && if (ArraySize && !ArraySize->isTypeDependent() &&
!ArraySize->isValueDependent() && !ArraySize->isValueDependent() &&
!ArraySize->isIntegerConstantExpr(Context)) !ArraySize->isIntegerConstantExpr(Context))