From 6b88c905046411fc906faac634f133f6e70bc92c Mon Sep 17 00:00:00 2001 From: Chris Gregory Date: Mon, 11 Mar 2019 21:04:34 -0400 Subject: [PATCH] impl FromIterator for Result: Use assert_eq! instead of assert! --- src/libcore/result.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libcore/result.rs b/src/libcore/result.rs index 92d29f6ee8a30..2bd6b536301e8 100644 --- a/src/libcore/result.rs +++ b/src/libcore/result.rs @@ -1200,7 +1200,7 @@ impl> FromIterator> for Result { /// let res: Result, &'static str> = v.iter().map(|x: &u32| /// x.checked_add(1).ok_or("Overflow!") /// ).collect(); - /// assert!(res == Ok(vec![2, 3])); + /// assert_eq!(res, Ok(vec![2, 3])); /// ``` #[inline] fn from_iter>>(iter: I) -> Result {