Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on (On | No) Syntactic Support for Error Handling. Parent comment
The answer is that errors.New just wraps the error message in an errorString struct, and the second line of `is` is a string comparison.
And as you demonstrate I could have tested it easily enough to confirm I was reading the code correctly...
The answer is that errors.New just wraps the error message in an errorString struct, and the second line of `is` is a string comparison.