- 
                Notifications
    
You must be signed in to change notification settings  - Fork 13.9k
 
Open
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 toolsT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.
Description
Location
https://doc.rust-lang.org/nightly/std/primitive.fn.html#trait-implementations-1
Summary
we now implement all of these traits for all function pointers. We should change the documentation to mention that.
we may also want to add a dummy impl for rustdoc for https://doc.rust-lang.org/nightly/std/marker/trait.FnPtr.html, similar to
rust/library/core/src/primitive_docs.rs
Lines 1574 to 1583 in 6f8c055
| // Fake impl that's only really used for docs. | |
| #[cfg(doc)] | |
| #[stable(feature = "rust1", since = "1.0.0")] | |
| #[doc(fake_variadic)] | |
| /// This trait is implemented on function pointers with any number of arguments. | |
| impl<Ret, T> Clone for fn(T) -> Ret { | |
| fn clone(&self) -> Self { | |
| loop {} | |
| } | |
| } | 
mj10021 and joseluisyaegeristhitesh
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 toolsT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.