mirror of
https://github.com/rust-lang/cargo.git
synced 2025-10-01 11:30:39 +00:00
refactor(source): Hide functions not needed elsewhere
This commit is contained in:
parent
b89d18b4a6
commit
4982455898
@ -91,7 +91,7 @@ impl<'gctx> PathSource<'gctx> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Gets the last modified file in a package.
|
/// Gets the last modified file in a package.
|
||||||
pub fn last_modified_file(&self, pkg: &Package) -> CargoResult<(FileTime, PathBuf)> {
|
fn last_modified_file(&self, pkg: &Package) -> CargoResult<(FileTime, PathBuf)> {
|
||||||
if self.package.is_none() {
|
if self.package.is_none() {
|
||||||
return Err(internal(format!(
|
return Err(internal(format!(
|
||||||
"BUG: source `{:?}` was not loaded",
|
"BUG: source `{:?}` was not loaded",
|
||||||
@ -271,7 +271,7 @@ impl<'gctx> RecursivePathSource<'gctx> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Gets the last modified file in a package.
|
/// Gets the last modified file in a package.
|
||||||
pub fn last_modified_file(&self, pkg: &Package) -> CargoResult<(FileTime, PathBuf)> {
|
fn last_modified_file(&self, pkg: &Package) -> CargoResult<(FileTime, PathBuf)> {
|
||||||
if !self.loaded {
|
if !self.loaded {
|
||||||
return Err(internal(format!(
|
return Err(internal(format!(
|
||||||
"BUG: source `{:?}` was not loaded",
|
"BUG: source `{:?}` was not loaded",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user