Comment #0 by dlang-bugzilla — 2024-02-09T12:47:26Z
std.socket provides a way to construct a socket using an OS socket object (Windows SOCKET handle or file descriptor).
What is missing is the inverse operation: extract the handle from the Socket, making Socket relinquish ownership of it.
This will allow wrapping an OS socket handle into a Phobos Socket object temporarily, which is currently not possible without duplicating the OS handle (e.g. using "dup").