3 ms·
Besides the iota dance hack of "enums" in Go, apparently Go 1.23 is going to bring another one, magic fields. https://pkg.go.dev/structs@master https://pkg.go.
by pjmlp 2y ago
Besides the iota dance hack of "enums" in Go, apparently Go 1.23 is going to bring another one, magic fields.
https://pkg.go.dev/structs@master https://pkg.go.dev/structs@master
What more sane languages would use attributes for, Go 1.23 will do it like this,
type myStruct struct {
_ struct.HostLayout
}
Lovely design.