News for hackers. Stuff that matters.
Re:My favourite C++ footgun by gpderetta on Wednesday June 23, 2021 @06:20AM (#27602815)
During the standardization of C++17, a proposal specifying the left-to-right order of evaluation of parameters (and other operations) came up and the committee got very close to accepting it, but in the end there were concrete examples in actual code that was worse of because of the proposal, so it was unfortunately weakened at the last minute.
Re:My favourite C++ footgun by simiones on Wednesday June 23, 2021 @10:50AM (#27605187)
Looking at the proposal in question [0], it seems very sad that the alternate, not recommended, choice was made instead [1] , especially since the reasoning seems to have not been put down in writing anywhere. The paper does mention that the difference in performance was <4%, with both improvements and worsening being seen by the VC++ implementers.

[0] http://open-std.org/JTC1/SC22/WG21/docs/papers/2016/p0145r3....

[1] http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/p040...