Author: rsmith
Date: Wed Dec 14 15:55:23 2011
New Revision: 146596

URL: http://llvm.org/viewvc/llvm-project?rev=146596&view=rev
Log:
Halve the constexpr recursion depth in this test in an attempt to make the
freebsd bots happy. In the longer term, we should have a mechanism for moving
constexpr recursion off the call stack, to support the default limit of 512
suggested by the standard.

Modified:
    cfe/trunk/test/CXX/expr/expr.const/p2-0x.cpp

Modified: cfe/trunk/test/CXX/expr/expr.const/p2-0x.cpp
URL: 
http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CXX/expr/expr.const/p2-0x.cpp?rev=146596&r1=146595&r2=146596&view=diff
==============================================================================
--- cfe/trunk/test/CXX/expr/expr.const/p2-0x.cpp (original)
+++ cfe/trunk/test/CXX/expr/expr.const/p2-0x.cpp Wed Dec 14 15:55:23 2011
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -fsyntax-only -std=c++11 -pedantic -verify -fcxx-exceptions 
%s
+// RUN: %clang_cc1 -fsyntax-only -std=c++11 -pedantic -verify -fcxx-exceptions 
%s -fconstexpr-depth 256
 
 // A conditional-expression is a core constant expression unless it involves 
one
 // of the following as a potentially evaluated subexpression [...]:
@@ -95,11 +95,11 @@
 //   exceed the implementation-defined recursion limits (see Annex B);
 namespace RecursionLimits {
   constexpr int RecurseForever(int n) {
-    return n + RecurseForever(n+1); // expected-note {{constexpr evaluation 
exceeded maximum depth of 512 calls}}
+    return n + RecurseForever(n+1); // expected-note {{constexpr evaluation 
exceeded maximum depth of 256 calls}}
   }
   struct AlsoRecurseForever {
     constexpr AlsoRecurseForever(int n) :
-      n(AlsoRecurseForever(n+1).n) // expected-note {{constexpr evaluation 
exceeded maximum depth of 512 calls}}
+      n(AlsoRecurseForever(n+1).n) // expected-note {{constexpr evaluation 
exceeded maximum depth of 256 calls}}
     {}
     int n;
   };


_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to