Date
2010-08-01.00:00:00
Message id
2882

Content

It is not clear what happens when a program violates the limits on constexpr function recursion in a context that does not require a constant expression. For example,

  constexpr int f(int i) { return f(i); }
  const int i = f(1);   // error, undefined behavior, or dynamic initialization?

(Presumably the “within its resource limits” caveat of 4.1 [intro.compliance] paragraph 2 would effectively result in undefined behavior in a context that required a constant expression.)