HN2
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
4ad
on Feb 12, 2014
|
parent
|
context
|
favorite
| on:
Toward Go 1.3
Of course you can, error is an interface, any number of concrete types can satisfy it, and you can use type assertions or type switches to unbox (and use) that concrete type.
This is a widely used idiom in Go.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search:
This is a widely used idiom in Go.