don't use dyn_iter for newtons_method_helper

This commit is contained in:
Simon Gardling 2022-05-16 13:32:11 -04:00
parent c7e8865d7e
commit 50ef1d17f9
2 changed files with 5 additions and 1 deletions

View File

@ -242,11 +242,14 @@ impl<'a> std::fmt::Debug for Hint<'a> {
}
impl<'a> Hint<'a> {
#[inline]
pub const fn is_none(&self) -> bool { matches!(&self, &Hint::None) }
#[inline]
#[allow(dead_code)]
pub const fn is_some(&self) -> bool { !self.is_none() }
#[inline]
#[allow(dead_code)]
pub const fn is_single(&self) -> bool { matches!(&self, &Hint::Single(_)) }

View File

@ -262,7 +262,8 @@ impl FunctionEntry {
_ => unreachable!(),
};
dyn_iter(&newtons_method_output)
newtons_method_output
.iter()
.map(|x| Value::new(*x, self.function.get(*x)))
.collect()
}