Skip to content

Commit 79f73a7

Browse files
committed
docs: explain the existence of duplicated_inode
1 parent 9bb7a7e commit 79f73a7

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/hardlink/hardlink_list/reflection.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,10 @@ pub enum ConversionError {
128128
}
129129

130130
impl ConversionError {
131+
/// Convenient function to convert an [`InodeKey`] into a [`ConversionError::DuplicatedInode`].
132+
///
133+
/// We don't embed [`InodeKey`] directly into [`ConversionError::DuplicatedInode`] because of
134+
/// their difference in visibility: One is private, the other public.
131135
fn duplicated_inode(InodeKey { ino, dev }: InodeKey) -> Self {
132136
ConversionError::DuplicatedInode(ino, dev)
133137
}

0 commit comments

Comments
 (0)