1 // Test that we catch excessive recursion. 2 // { dg-do compile { target c++11 } } 3 // { dg-options "-fconstexpr-depth=5" } 4 // { dg-prune-output "in constexpr expansion" } f(int i)5constexpr int f (int i) { return f (i-1); } // { dg-message "in .constexpr. expansion of " } 6 constexpr int i = f(42); // { dg-error ".constexpr. evaluation depth|in .constexpr. expansion of " } 7