4 ms·
.
by bun_terminator 2y ago
.
- beached_whale 2y agosure about that? It does, happen to, work on libstdc++/libc++/MS STL but it's not specified to work anywhere but std::tie. The existing practice is to cast to void.
- alexvitkov 2y agocan you show an example how? I can't find a case where std::ignore compiles inside a structured binding declaration. https://godbolt.org/z/sjefeGvPf https://godbolt.org/z/sjefeGvPf https://godbolt.org/z/8a7Ps4KdW https://godbolt.org/z/8a7Ps4KdW
- beached_whale 2y agoit will work for assignment/ construction, but isn't part of std c++ is what i mean. at least not yet. structured binding wont, but in the future c++ 26, _ should work there and other places
- alexvitkov 2y agostd::ignore doesn't work in the context of structured bindings. And even if it did, "we already have this" has never stopped the C++ committee from adding something before :)
- ReleaseCandidat 2y agoYes, the "skill" of the commitee to discuss some feature for a really looooooong time and then come up with a solution which is going to be (half) fixed in the next standard always astonishes mé :). I guess with C++38 we'll get a `always_definetly_ignore_this_wothout_any_diagnostic_whatsoever`.
- ReleaseCandidat 2y agoNo, that's why `maybe_unused` has been needed.
- dundarious 2y agoIf you replace your whole comment with ".", I'm just going to automatically down vote it, so the effect is worse than whatever was originally there. These kinds of "masking" edits prevent good communication. If you want us all to disregard a comment you now totally disown, then just write an edit that prepends/appends that.
- layer8 2y agoMaybe they are fine with being downvoted and just want to prevent readers wasting any further time with their comment.
- dundarious 2y agoWriting that in an edit is completely valid -- we're grown up enough to weigh whether to bother reading the comment then. Replacing the whole thing with just "." is not acceptable, IMO. If they're fine with accepting the down votes either way, I still want to register my complaint, pointless as it may be in practice.
- layer8 2y agoIt's perfectly okay that you downvote, as that supports the goal of demoting the comment. (The effects of up/downvoting on comment ranking trumps the effect on the author's karma, IMO.) However I don't agree that pseudo-deleting is unacceptable, if for example it contained an incorrect argument and the author thinks there is no value anymore in someone reading it.
- dundarious 2y agoSo they presumably think they were fully wrong. Wrong about what? It's often useful to know about mistaken assumptions, etc. Now all the "corrections" in the replies are harder to comprehend. Everybody's work is devalued and made harder as a result of the pseudo-delete.
- 2y ago