mirror of
https://github.com/martinvonz/jj.git
synced 2025-02-07 21:27:06 +00:00
tree: make sub_tree_recursive()
public
These functions (in `Tree` and `MergedTree`) are safe to use. We have a duplicate of these functions at Google, which would be nice to avoid.
This commit is contained in:
parent
50dd78eb8f
commit
cd5e82d0d3
2 changed files with 4 additions and 2 deletions
|
@ -268,7 +268,8 @@ impl MergedTree {
|
|||
}
|
||||
}
|
||||
|
||||
fn sub_tree_recursive(
|
||||
/// Look up the tree at the path indicated by `components`.
|
||||
pub fn sub_tree_recursive(
|
||||
&self,
|
||||
components: RepoPathComponentsIter,
|
||||
) -> BackendResult<Option<MergedTree>> {
|
||||
|
|
|
@ -154,7 +154,8 @@ impl Tree {
|
|||
self.store.get_tree(subdir, id).unwrap()
|
||||
}
|
||||
|
||||
fn sub_tree_recursive(
|
||||
/// Look up the tree at the path indicated by `components`.
|
||||
pub fn sub_tree_recursive(
|
||||
&self,
|
||||
components: RepoPathComponentsIter,
|
||||
) -> BackendResult<Option<Tree>> {
|
||||
|
|
Loading…
Reference in a new issue