Perform stricter/more accurate checking for C99 constant expressions
in Sema, per discussion on mailing list.  This doesn't cause any changes 
in the test results.  I'll probably add some more tests at some point, 
but it's an open question what we need to accept to be compatible with 
real code.

This doesn't touch the existing isConstantExpr method on Expr; that 
should be addressed somehow eventually (either removed or refined to 
whatever is appropriate).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@51318 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/Sema.h b/lib/Sema/Sema.h
index b9b922a..e7e6605 100644
--- a/lib/Sema/Sema.h
+++ b/lib/Sema/Sema.h
@@ -857,6 +857,9 @@
   bool CheckInitializerListTypes(InitListExpr*& IList, QualType &DeclType,
                                  bool topLevel, unsigned& startIndex);
   bool CheckForConstantInitializer(Expr *e, QualType t);
+  bool CheckArithmeticConstantExpression(const Expr* e);
+  bool CheckAddressConstantExpression(const Expr* e);
+  bool CheckAddressConstantExpressionLValue(const Expr* e);
   
   StringLiteral *IsStringLiteralInit(Expr *Init, QualType DeclType);
   bool CheckStringLiteralInit(StringLiteral *strLiteral, QualType &DeclT);