refactor(lint): improve and adapt to lints

This commit is contained in:
EdJoPaTo
2023-05-22 11:50:09 +02:00
parent 4d3a1eac30
commit 8a53caced7
3 changed files with 14 additions and 3 deletions
+1
View File
@@ -23,6 +23,7 @@ pub type TreeIdentifierVec = Vec<usize>;
/// assert_eq!(branch, []);
/// assert_eq!(leaf, None);
/// ```
#[must_use]
pub const fn get_without_leaf(identifier: TreeIdentifier) -> (TreeIdentifier, Option<usize>) {
match identifier {
[branch @ .., leaf] => (branch, Some(*leaf)),