PR c++/82081 - tail call optimization breaks noexcept
If a noexcept function calls a function that might throw, doing the tail call optimization means that an exception thrown in the called function will propagate out, breaking the noexcept specification. So we need to prevent the optimization in that case. * tree-tailcall.c (find_tail_calls): Don't turn a call from a nothrow function to a might-throw function into a tail call. From-SVN: r270656
Showing
gcc/testsuite/g++.dg/tree-ssa/tail-call-1.C
0 → 100644
Please
register
or
sign in
to comment