Skip to content

Commit 2ea187f

Browse files
committed
doc: mention throw/try/catch in the Option section, so people can find it easier
1 parent d44fe50 commit 2ea187f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

doc/docs.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1391,6 +1391,7 @@ If you don't need to return an error message, you can simply `return none` (this
13911391

13921392
This is the primary mechanism for error handling in V. They are still values, like in Go,
13931393
but the advantage is that errors can't be unhandled, and handling them is a lot less verbose.
1394+
Unlike other languages, V does not handle exceptions with `throw/try/catch` blocks.
13941395

13951396
`err` is defined inside an `or` block and is set to the string message passed
13961397
to the `error()` function. `err` is empty if `none` was returned.

0 commit comments

Comments
 (0)