Generics introduces a whole new kind of interface to Go: one based not on methods, but on type sets. Let’s explore the possibilities.
All tagged union
Generics introduces a whole new kind of interface to Go: one based not on methods, but on type sets. Let’s explore the possibilities.
To celebrate the first anniversary of generics in Go, let’s build something practical and useful: a generic Set type, and add some neat methods to it. Ready for fun?