Skip to content

Commit

Permalink
rm low value function
Browse files Browse the repository at this point in the history
  • Loading branch information
sourcefrog committed Sep 14, 2023
1 parent 2db2d06 commit a88d61f
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
5 changes: 0 additions & 5 deletions src/source.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,6 @@ impl SourceFile {
pub fn tree_relative_slashes(&self) -> String {
self.tree_relative_path.to_slash_path()
}

/// Return the path of this file relative to the base of the source tree.
pub fn tree_relative_path(&self) -> &Utf8Path {
&self.tree_relative_path
}
}

/// A package built and tested as a unit.
Expand Down
2 changes: 1 addition & 1 deletion src/visit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ impl<'ast> Visit<'ast> for DiscoveryVisitor<'_> {
// Having determined the directory then we can look for either
// `foo.rs` or `foo/mod.rs`.
if node.content.is_none() {
let my_path: &Utf8Path = self.source_file.tree_relative_path();
let my_path = &self.source_file.tree_relative_path;
// Maybe matching on the name here is no the right approach and
// we should instead remember how this file was found?
let dir = if my_path.ends_with("mod.rs")
Expand Down

0 comments on commit a88d61f

Please sign in to comment.