Skip to content

The Path::join method is not very discoverable #106219

Closed
@albertlarsan68

Description

@albertlarsan68

Location

std::path::PathBuf::push()'s docs

Summary

There should be a link to the std::path::Path::join() method. It is a method that is already linked in the other way, and can reduce the likelihood of things like

-    let stamp_file = {
-        let mut s = build.out.clone();
-        s.push("rustfmt.stamp");
-        s
-    };
+    let stamp_file = build.out.join("rustfmt.stamp");

happening.

Metadata

Metadata

Assignees

Labels

A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsE-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.T-libsRelevant to the library team, which will review and decide on the PR/issue.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions