Go 1.27 adds generic methods, but not on interfaces

Generic Methods in Go 1.27

Go 1.27 adds generic methods, but not on interfaces

Go 1.27, released August 2026, lets methods define their own type parameters without adding them to the receiving struct, removing a limitation since generics arrived in 1.18. The compiler's monomorphization clashes with runtime interface dispatch, so generic methods are allowed on concrete types but not interfaces, which is why the feature took years.

Ultimately, the Go team decided to separate generic methods from interfaces.

More from this day

2026-08-20