4 ms·
I don't see interface{} as an improvement over code generation.
by jacques_chester 6y ago
I don't see interface{} as an improvement over code generation.
- throwaway894345 6y agoI think you'll find that your opinion is very fringe, but by all means, go forth and use code generation.
- jacques_chester 6y agoMy opinion is that I greatly prefer generics to either.
- loopz 6y agoHaving genetics as a good option is great. Using interface{} works too, but is a kludge if you have to do it alot. You lose performance to reflection and gain runtime errors that are hard to handle. It's not the best part of Go, far from it.