diff --git a/rust/hg-core/src/utils/hg_path.rs b/rust/hg-core/src/utils/hg_path.rs --- a/rust/hg-core/src/utils/hg_path.rs +++ b/rust/hg-core/src/utils/hg_path.rs @@ -479,10 +479,11 @@ impl Extend for HgPathBuf { } } +/// Create a new [`OsString`] from types referenceable as [`HgPath`]. +/// /// TODO: Once is /// implemented, these conversion utils will have to work differently depending /// on the repository encoding: either `UTF-8` or `MBCS`. - pub fn hg_path_to_os_string>( hg_path: P, ) -> Result { @@ -498,12 +499,14 @@ pub fn hg_path_to_os_string>( hg_path: P, ) -> Result { Ok(Path::new(&hg_path_to_os_string(hg_path)?).to_path_buf()) } +/// Create a new [`HgPathBuf`] from types referenceable as [`OsStr`]. pub fn os_string_to_hg_path_buf>( os_string: S, ) -> Result { @@ -520,6 +523,7 @@ pub fn os_string_to_hg_path_buf>( path: P, ) -> Result {