4 ms·
One could use a generics library to emulate something like Go's struct field tags, which decouple "external" fields names from the actual field names. Something
by danidiaz 9y ago
One could use a generics library to emulate something like Go's struct field tags, which decouple "external" fields names from the actual field names. Something like this is explained from 48:50 in this talk: https://skillsmatter.com/skillscasts/10181-fun-with-sum-and-product-types https://skillsmatter.com/skillscasts/10181-fun-with-sum-and-...
But perhaps it wouldn't save much code compared to custom-made parsers.