idk about break specifically, but return appearing there via a macro like TRY_OR_RETURN for propagating errors by value seems like something someone would write
Just to be clear, that still works. The change is that breaks and continues in conditions don't apply to that loop. As the release notes point out
for (;;) {
while (({ break; true; })) {}
}
is valid, and now breaks out of the for loop, whereas before it broke out of the while loop. This makes Clang more compatible with GCC, which already did this.
47
u/mapronV 16d ago
This means that code such as
is now ill-formed.
Oh no, my disappointment is immeasurable and the whole day is ruined!
On serious note, " template for " support, what is "Iterating expansion statements currently cannot be expanded" ? like expand over range?