The description of the capy::cond::canceled in https://github.com/cppalliance/capy/blob/develop/include/boost/capy/cond.hpp#L50 says:
An error_code compares equal to canceled when:
(1) the operation's stop token was activated,
(2) the I/O object's cancel() was called,
(3) or a platform cancellation error occurred.
Conflating the third reason (platform-specific cancellation) with the first two makes capy::cond::canceled less usable. The first two correspond to stop signal from Senders/Receivers and could be mapped on the stop slot. But the third one just doesn't fit: it may mean, "the socket was closed on the other end by the other system" (CONNRESET). It just looks like an "error", much like "couldn't connect".
What is the motivation of representing all three under the same condition?
The description of the
capy::cond::canceledin https://github.com/cppalliance/capy/blob/develop/include/boost/capy/cond.hpp#L50 says:Conflating the third reason (platform-specific cancellation) with the first two makes
capy::cond::canceledless usable. The first two correspond tostopsignal from Senders/Receivers and could be mapped on thestopslot. But the third one just doesn't fit: it may mean, "the socket was closed on the other end by the other system" (CONNRESET). It just looks like an "error", much like "couldn't connect".What is the motivation of representing all three under the same condition?