http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48909
Summary: [C++0x]internal compiler error: in cxx_eval_conditional_expression, at cp/semantics.c:6213 Product: gcc Version: 4.6.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassig...@gcc.gnu.org ReportedBy: sscr...@gmail.com Souce: constexpr int const * is_sorted_until(int const * first, int const * last) { return first == last || first + 1 == last ? last : (*(first + 1) < *first) != false ? first + 1 : is_sorted_until(first + 1, last); } int main() { static constexpr int array[2] = {0, 1}; constexpr int const * last = is_sorted_until(array, array + 2); } Compile errors: a.cpp: In function 'int main()': a.cpp:11:56: in constexpr expansion of 'is_sorted_until(((const int*)(& b)), (((const int*)(& b)) + 8u))' a.cpp:11:56: internal compiler error: in cxx_eval_conditional_expression, at cp/semantics.c:6213 Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions.