Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion _chapters/08-ex5.md
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ Case transformations are functions that act on `String`s and transform character
| `uppercase()` | Converts the entire string to upper-case characters | `WE HOLD THESE TRUTHS TO BE SELF-EVIDENT` |
| `lowercase()` | Converts the entire string to lower-case characters | `we hold these truths to be self-evident` |
| `uppercasefirst()` | Converts the first character of the string to upper-case | `We hold these truths to be self-evident` |
| `lowercasefirst()` | Converts the first character of the string ot lower-case | `we hold these truths to be self-evident` |
| `lowercasefirst()` | Converts the first character of the string to lower-case | `we hold these truths to be self-evident` |

### Testing and attributes

Expand Down
2 changes: 1 addition & 1 deletion _chapters/11-ex8.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ This structure is demonstrated by the following function, creating a resilient,
end
```

There is no need to specify a variable to hold the error instance. Similarly to not testing for the identity of the error, such a clause would result in a catch-all sequence. This is not necessarily a bad thing, but good code is responsive to the nature of errors, rather than their mere existence, and good programmers would always be interested in _why_ their code doesn't work, not merely in the fact that it failed to execute. Therefore, good code would check for the types of exceptions and only use catch-alls sparingly.
There is no need to specify a variable to hold the error instance. Similarly to not testing for the identity of the error, such a clause would result in a catch-all sequence. This is not necessarily a bad thing, but good code is responsive to the nature of errors, rather than their mere existence, and good programmers would always be interested in _why_ their code doesn't work, not merely in the fact that it failed to execute. Therefore, good code would check for the types of exceptions and only use catch-all sparingly.

#### One-line `try`/`catch`

Expand Down