On Sun, 2016-09-11 at 03:02 +1000, Kiki Sugiaman wrote:
> If I know every possible type (that implements the interface), I can
> do 
> a type switch. But if I don't, there's no way to do this then?

reflect will help here:

https://play.golang.org/p/h76XV_eTJx

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to