Skip to content

Commit 6967751

Browse files
Fix mix up in comments
1 parent 74a2fad commit 6967751

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

crates/project-model/src/sysroot.rs

+7-7
Original file line numberDiff line numberDiff line change
@@ -36,19 +36,19 @@ impl ops::Index<SysrootCrate> for Sysroot {
3636
}
3737

3838
impl Sysroot {
39-
/// Returns sysroot directory, where `bin/`, `etc/`, `lib/`, `libexec/`
39+
/// Returns sysroot "root" directory, where `bin/`, `etc/`, `lib/`, `libexec/`
4040
/// subfolder live, like:
41-
/// `$HOME/.rustup/toolchains/nightly-2022-07-23-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library`
42-
pub fn src_root(&self) -> &AbsPath {
43-
&self.src_root
44-
}
45-
46-
/// Returns sysroot "src" directory, where stdlib sources are located, like:
4741
/// `$HOME/.rustup/toolchains/nightly-2022-07-23-x86_64-unknown-linux-gnu`
4842
pub fn root(&self) -> &AbsPath {
4943
&self.root
5044
}
5145

46+
/// Returns the sysroot "source" directory, where stdlib sources are located, like:
47+
/// `$HOME/.rustup/toolchains/nightly-2022-07-23-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library`
48+
pub fn src_root(&self) -> &AbsPath {
49+
&self.src_root
50+
}
51+
5252
pub fn public_deps(&self) -> impl Iterator<Item = (&'static str, SysrootCrate, bool)> + '_ {
5353
// core is added as a dependency before std in order to
5454
// mimic rustcs dependency order

0 commit comments

Comments
 (0)