-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
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.
Description
Feature gates: #![feature(option_owned)]
, #![feature(result_owned)]
This is a tracking issue for owned
method on Option
and Result
.
Public API
// alloc::option
impl<T: ?Sized> Option<&T> {
pub fn owned(self) -> Option<T::Owned>
where
T: ToOwned;
}
impl<T: ?Sized> Option<&mut T> {
pub fn owned(self) -> Option<T::Owned>
where
T: ToOwned;
}
// alloc::result
impl<T: ?Sized, E> Result<&T, E> {
pub fn owned(self) -> Result<T::Owned, E>
where
T: ToOwned;
}
impl<T: ?Sized, E> Result<&mut T, E> {
pub fn owned(self) -> Result<T::Owned, E>
where
T: ToOwned;
}
Steps / History
- Implementation: Add
Option::owned
#98061 - Final comment period (FCP)1
- Stabilization PR
Unresolved Questions
- None yet.
Footnotes
compiler-errors, 0xdeafbeef and thomcc
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.