https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86184
--- Comment #5 from Marek Polacek <mpolacek at gcc dot gnu.org> --- Runtime test: int j; struct X { X() { j++; } operator bool() { return true; } }; /* Only create X once. */ bool b = X() ?: false; bool b2 = X() ? X() : false; int main () { if (j != 3) __builtin_abort (); }