TIL: there is a std::kill_dependency function, and its been deprecated in C++26
https://en.cppreference.com/w/cpp/atomic/kill_dependency.html
#cpp
#cplusplus
std::kill_dependency - cppreference.com

@meetingcpp I wonder who writes this kind of code, especially in production?
@madduci it better be high level then :)
@madduci @meetingcpp Well, that nobody used it is part of why it's gone. It's a shame that compilers have found implementing memory_order_consume so difficult.

@meetingcpp
(constexpr since C++26)
(deprecated in C++26)

That is....interesting

@asperamanca indeed :)
But I wonder if thats reflected correctly on cppreference. It might be different in the current draft.

I guess if you want to make as much functions as possible constexpr, then it makes sense to also do that for deprecated ones.

@meetingcpp @hanadusikova might have an idea what's the story behind that

@asperamanca @hanadusikova sure, but I think this is already explained. Making it constexpr makes sense even with deprecation. As folks are using this function out there.

@jfbastien pointed to this paper about memory_order_consume:
https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2018/p0750r1.html

Which gives this some more context. C++26 also deprecates memory_order_consume, as no one has implemented it.

p0750r1: Consume