Skip to content

Commit c5c80d5

Browse files
authored
Merge pull request #3158 from sozysozbot/patch-1
Fix typo: `or_or` -> `ok_or`
2 parents a0df602 + 056b5f6 commit c5c80d5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

text/3137-let-else.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -311,7 +311,7 @@ context cannot be guaranteed to continue soundly without assignment, and no alte
311311

312312
## Alternatives
313313

314-
While this feature can partly be covered by functions such `or_or`/`ok_or_else` on the `Option` and `Result` types combined with the Try operator (`?`),
314+
While this feature can partly be covered by functions such `ok_or`/`ok_or_else` on the `Option` and `Result` types combined with the Try operator (`?`),
315315
such functions do not exist automatically on custom enum types and require non-obvious and non-trivial implementation, and may not be map-able
316316
to `Option`/`Result`-style functions at all (especially for enums where the "success" variant is contextual and there are many variants).
317317
These functions will also not work for code which wishes to return something other than `Option` or `Result`.

0 commit comments

Comments
 (0)