feat(errors): Improve comments and hints

This commit is contained in:
mokou
2022-07-14 18:02:33 +02:00
parent 5e1ca4b995
commit c34e2adcbb
7 changed files with 16 additions and 7 deletions

View File

@@ -603,7 +603,10 @@ name = "errors3"
path = "exercises/error_handling/errors3.rs"
mode = "compile"
hint = """
If other functions can return a `Result`, why shouldn't `main`?"""
If other functions can return a `Result`, why shouldn't `main`? It's a fairly common
convention to return something like Result<(), ErrorType> from your main function.
The unit (`()`) type is there because nothing is really needed in terms of positive
results."""
[[exercises]]
name = "errors4"