-
-
Notifications
You must be signed in to change notification settings - Fork 14.9k
Tracking Issue for tcplistener_into_incoming #88373
Copy link
Copy link
Open
Labels
C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCT-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCT-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Feature gate:
#![feature(tcplistener_into_incoming)]This is a tracking issue for #88339
The
TcpListener::incomingmethod is really useful, however for some use cases the borrow it introduces is needlessly restricting. Thus, an owned variant is added.Public API
Steps / History
Unresolved Questions
IntoIncomingcould provide methods that allow access to (or getting back) theTcpListener. I decided against it, but they could be added if there is a use caseinto_incomingmethod should return an opaqueimpl IntoIteratorso thatIntoIncomingis not public API, but that would be inconsistent with the rest ofstd.