1 // { dg-do compile { target c++11 } }
2 
may_throw(bool decide)3 constexpr int may_throw(bool decide) {
4 	return decide ? 42 : throw -1; // { dg-error "throw" }
5 }
6 
7 constexpr int x = may_throw(false); // { dg-message "may_throw" }
8 constexpr int y = may_throw(true);
9