3 ms·
Rust uses Result. Checked exceptions are Java's analogue of Result.
by twic 4y ago
Rust uses Result. Checked exceptions are Java's analogue of Result.
- knorker 4y agoI disagree. Exceptions are a fundamentally different control flow. Exceptions are exceptions. Return values are not. I would not call std::optional in C++ any form of checked exception, and the difference isn't that std::optional doesn't carry value-missing metadata.