Booleans feel like they make sense for our data or state, but they make sense for our logic
This means using it inside a function as a conditional variable
{ completed: boolean, failed: boolean, in_progress: boolean, }
easy to miss in if statement of the client code
Enum Data
{ status: 'failed' | 'completed' | 'in_progress' }
Check authorization
fn check_permissions(user: User) -> bool { false // no one is allowed to do anything i guess }
the application logic meaning of the value cannot be inferred from the type.
enum PermissionCheck { Allowed, NotPermitted(reason: String), }

Seonglae Cho