Created
July 14, 2022 14:54
-
-
Save nwillc/ab2aad4b51bed6a83ffac9c1db3810a4 to your computer and use it in GitHub Desktop.
Example Go that might panic
This file contains hidden or 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
func CaculateSomething(i int) (result int, err error) { | |
// Does a bunch of math to calculate a value, or | |
// returns an error when it can't. | |
// ... the magic ... | |
return result, err | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment