fix: set correct type of error for max

This commit is contained in:
2025-11-16 09:33:15 +01:00
parent 1688b2acc2
commit a8fbfabbcc
2 changed files with 2 additions and 1 deletions

View File

@@ -9,7 +9,7 @@ fn max_of(values: Vec<u16>) -> Result<Outcome, FailedTo> {
values
.iter()
.max()
.ok_or(FailedTo::FindMin)
.ok_or(FailedTo::FindMax)
.map(|min| Outcome::Scalar(*min))
})
}

View File

@@ -4,6 +4,7 @@
#[derive(Debug, PartialEq, PartialOrd, Eq, Ord, Clone, Copy, Hash)]
pub enum E {
FindMax,
FindMin,
ProcessInput,
SumValues,