Skip to content

Implement I/O-safe traits on Socket#324

Closed
notgull wants to merge 2 commits intorust-lang:masterfrom
notgull:master
Closed

Implement I/O-safe traits on Socket#324
notgull wants to merge 2 commits intorust-lang:masterfrom
notgull:master

Conversation

@notgull
Copy link
Copy Markdown
Contributor

@notgull notgull commented Aug 11, 2022

This PR adds a new feature, io_safety, which requires Rust 1.63. This feature implements AsFd/AsSocket on Socket, as well as From<OwnedFd/OwnedSocket> and Into<OwnedFd/OwnedSocket>.

See also: sunfishcode/io-lifetimes#38

@Darksonn
Copy link
Copy Markdown
Member

Socket2 will soon be releasing a version with an MSRV that supports this without the use of conditional compilation, so I believe the feature can just be removed.

@Thomasdezeeuw
Copy link
Copy Markdown
Collaborator

@notgull you beat me to it, I already part of this work earlier, but waited until 1.63 to be released before pushing it. I gave to author created in my commit in #325.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants