Skip to content

Commit 6017ed6

Browse files
committed
fix(type-driven-book): add missing HealthValue definition
1 parent e83aa94 commit 6017ed6

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

type-driven-correctness-book/src/ch07-validated-boundaries-parse-dont-validate.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1021,6 +1021,11 @@ Instead of collapsing everything into `has_critical_events: bool`, classify each
10211021
parsed SEL event into a per-subsystem health bucket:
10221022

10231023
```rust,ignore
1024+
/// Worst-of health value — Ord gives us `.max()` for free.
1025+
/// (Full definition in ch18; reproduced here for the SEL pipeline.)
1026+
#[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord)]
1027+
pub enum HealthValue { OK, Warning, Critical }
1028+
10241029
/// Health contribution from a single SEL event, classified by subsystem.
10251030
#[derive(Debug, Clone)]
10261031
pub enum SubsystemHealth {

0 commit comments

Comments
 (0)