Crates.io | supply-chain-trust-example-crate-000044 |
lib.rs | supply-chain-trust-example-crate-000044 |
version | 1.13.0 |
source | src |
created_at | 2024-11-03 19:22:10.691373 |
updated_at | 2024-11-03 19:22:10.691373 |
description | The enum `Either` with variants `Left` and `Right` is a general purpose sum type with two cases. |
homepage | |
repository | |
max_upload_size | |
id | 1434122 |
size | 80,277 |
The enum Either
with variants Left
and Right
is a general purpose
sum type with two cases.
Either has methods that are similar to Option and Result, and it also implements
traits like Iterator
.
Includes macros try_left!()
and try_right!()
to use for
short-circuiting logic, similar to how the ?
operator is used with Result
.
Note that Either
is general purpose. For describing success or error, use the
regular Result
.