-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
In #66, we discussed advising at most one `log.Fatal` per program. This can be split into two pieces of guidance: 1. exit only in main 2. exit only once Applying to both, `os.Exit` and `log.Fatal`. This adds (1) as a guidance to the style guide, and (2) as an optional "upgrade" for extra points. At minimum, (1) gives us easy-to-follow control flow and testability outside main. If readers are sold on that, (2) gives us testable `main()` logic. Resolves #66
- Loading branch information
Showing
2 changed files
with
161 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters