-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsArea: Documentation for any part of the project, including the compiler, standard library, and toolsC-bugCategory: This is a bug.Category: This is a bug.F-precise_capturing`#![feature(precise_capturing)]``#![feature(precise_capturing)]`T-rustfmtRelevant to the rustfmt team, which will review and decide on the PR/issue.Relevant to the rustfmt team, which will review and decide on the PR/issue.T-styleRelevant to the style team, which will review and decide on the PR/issue.Relevant to the style team, which will review and decide on the PR/issue.
Description
Location
rust/src/doc/style-guide/src/nightly.md
Lines 9 to 19 in d9e5539
### `feature(precise_capturing)` | |
A `use<'a, T>` precise capturing bound is formatted as if it were a single path segment with non-turbofished angle-bracketed args, like a trait bound whose identifier is `use`. | |
``` | |
fn foo() -> impl Sized + use<'a> {} | |
// is formatted analogously to: | |
fn foo() -> impl Sized + Use<'a> {} | |
``` |
Summary
I believe that precise capturing (#123432) was stabilized, but it's still listed as a nightly-only feature in the style guide.
rust/src/doc/style-guide/src/nightly.md
Lines 9 to 19 in d9e5539
### `feature(precise_capturing)` | |
A `use<'a, T>` precise capturing bound is formatted as if it were a single path segment with non-turbofished angle-bracketed args, like a trait bound whose identifier is `use`. | |
``` | |
fn foo() -> impl Sized + use<'a> {} | |
// is formatted analogously to: | |
fn foo() -> impl Sized + Use<'a> {} | |
``` |
I think these docs should be moved to a stable section. Also, rust-lang/rustfmt#6504, was recently filed and I'm wondering if t-style had any recommendations for sorting the precise capture syntax in a list of bounds.
Metadata
Metadata
Assignees
Labels
A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsArea: Documentation for any part of the project, including the compiler, standard library, and toolsC-bugCategory: This is a bug.Category: This is a bug.F-precise_capturing`#![feature(precise_capturing)]``#![feature(precise_capturing)]`T-rustfmtRelevant to the rustfmt team, which will review and decide on the PR/issue.Relevant to the rustfmt team, which will review and decide on the PR/issue.T-styleRelevant to the style team, which will review and decide on the PR/issue.Relevant to the style team, which will review and decide on the PR/issue.