>
> > Is this so bad?
>
> Yes, it's horrible as you'll loose any type information you had.
> Meaning the next thing you naturally had to do was type cast it, which
> isn't the nicest syntax to begin with.
> By then it's probably more work than just using if / else
>

So what you're saying is that Go needs a ternary operator and generics? ;)
But yeah, for assignment, you'd need a type specific operator, or you end
up with an if else (or at least an if) to do a type assertion, which
defeats the purpose... or just use if / else, agreed.

-- 
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