Skip to content

Commit

Permalink
Updated to Exception Handling page to use neutral phrasing (#786)
Browse files Browse the repository at this point in the history
  • Loading branch information
BigBoyBarney authored Oct 18, 2024
1 parent 65f13f6 commit 21e02ac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/syntax_and_semantics/exception_handling.md
Original file line number Diff line number Diff line change
Expand Up @@ -255,4 +255,4 @@ array[4] # raises because of IndexError
array[4]? # returns nil because of index out of bounds
```

The usual convention is to provide an alternative "question" method to signal that this variant of the method returns `nil` instead of raising. This lets the user choose whether she wants to deal with exceptions or with `nil`. Note, however, that this is not available for every method out there, as exceptions are still the preferred way because they don't pollute the code with error handling logic.
The usual convention is to provide an alternative "question" method to signal that this variant of the method returns `nil` instead of raising. This lets the user choose whether they want to deal with exceptions or with `nil`. Note, however, that this is not available for every method out there, as exceptions are still the preferred way because they don't pollute the code with error handling logic.

0 comments on commit 21e02ac

Please sign in to comment.