2 ms·
thanks :) I get this now. This would be useful if Go supported it. I've used enums before (but just as constant values), and I'd love to have them in Go. Iota
by marcus_holmes 8y ago
thanks :) I get this now. This would be useful if Go supported it.
I've used enums before (but just as constant values), and I'd love to have them in Go. Iota is nice, but as you say there's no constraint on the type. It seems like a good fit...