It's only a discussion right now but opaque + sum types = efficient oneofs github.com/golang/go/is...
This is an issue to discuss yet another form of sum type to Go. This is not a full proposal, and not a language change that I expect will be adopted in the near future. I am filing this issue as a ...