Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tracking Issue for const_borrow #91522

Closed
1 of 3 tasks
lilasta opened this issue Dec 4, 2021 · 4 comments
Closed
1 of 3 tasks

Tracking Issue for const_borrow #91522

lilasta opened this issue Dec 4, 2021 · 4 comments
Labels
C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC F-const_trait_impl `#![feature(const_trait_impl)]` T-libs-api Relevant to the library API team, which will review and decide on the PR/issue.

Comments

@lilasta
Copy link
Contributor

lilasta commented Dec 4, 2021

Feature gate: #![feature(const_borrow)]

This is a tracking issue for implementing const Borrow/BorrowMut.

Public API

// core::borrow
impl<T: ?Sized> const Borrow<T> for T
impl<T: ?Sized> const BorrowMut<T> for T
impl<T: ?Sized> const Borrow<T> for &T
impl<T: ?Sized> const Borrow<T> for &mut T
impl<T: ?Sized> const BorrowMut<T> for &mut T

// core::array
impl<T, const N: usize> const Borrow<[T]> for [T; N]
impl<T, const N: usize> const BorrowMut<[T]> for [T; N]

Steps / History

Unresolved Questions

  • None yet.
@lilasta lilasta added C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC T-libs-api Relevant to the library API team, which will review and decide on the PR/issue. labels Dec 4, 2021
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this issue Dec 11, 2021
Make `Borrow` and `BorrowMut` impls `const`

Tracking issue: rust-lang#91522
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this issue Dec 11, 2021
Make `Borrow` and `BorrowMut` impls `const`

Tracking issue: rust-lang#91522
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this issue Dec 11, 2021
Make `Borrow` and `BorrowMut` impls `const`

Tracking issue: rust-lang#91522
@DavidSkrundz
Copy link

It appears the implementation was removed in 76dbe29#diff-b8d90f158b67cb63e13a53302629ba287759aed739f9e10ee524d5ef8592b9ca. Is there an alternative or a plan to reintroduce the feature?

@lilasta
Copy link
Contributor Author

lilasta commented Apr 21, 2023

According to #110395, it will be restored after `~const' trait is reimplemented.

@workingjubilee workingjubilee added the F-const_trait_impl `#![feature(const_trait_impl)]` label Sep 19, 2023
@RalfJung
Copy link
Member

RalfJung commented Sep 7, 2024

Is any part of this feature left after #110393? Cc @fee1-dead

That PR removed a lot of rustc_const_unstable, likely all those tracking issues are outdated now.

@RalfJung
Copy link
Member

RalfJung commented Sep 8, 2024

I can't find any mention of 91522 in the codebase, so I''ll close this issue -- this feature has been removed.

@RalfJung RalfJung closed this as completed Sep 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC F-const_trait_impl `#![feature(const_trait_impl)]` T-libs-api Relevant to the library API team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

4 participants