Skip to content

Option utility functions #7

Description

@nagyors

Expand the µRust's Option implementation with more utility functions from the Rust std documentation, e.g.unwrap_or implementation

  • map / and_then (flatmap) — monadic chaining; eliminates nested match reasoning
  • unwrap_or_default — default-value fallback
  • zip — combine two Options
  • flatten — Option<Option> → Option
  • map / and_then for Result — error-propagation reasoning

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions