Skip to content

Commit 29756d8

Browse files
committed
extend panics documentation
1 parent 826b3ab commit 29756d8

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/common_traits/from_depth_first_iter.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,10 @@ where
247247

248248
/// # Panics
249249
///
250-
/// Panics if the `iter` is an empty iterator. It must contain at least one child node.
250+
/// Panics
251+
///
252+
/// * If the `iter` is an empty iterator; it must contain at least one child node.
253+
/// * If the `tree` is empty, it must have at least the `root`.
251254
fn push_dfs_under_root<I, V, M, P>(
252255
mut tree: Tree<V, M, P>,
253256
iter: I,

0 commit comments

Comments
 (0)