Closed leg100 closed 2 years ago
I've just seen an identical issue for sqlc, closed with a fairly reasonable objection: a generated accessor method may conflict with a field with the same name.
I've just seen an https://github.com/kyleconroy/sqlc/pull/387, closed with a fairly reasonable objection: a generated accessor method may conflict with a field with the same name.
Yea, that's a pretty good reason not to do it. I'll close this in favor of #44 (and a dupe #58) which solves this issue directly.
Might it be a good idea to provide accessor methods on the row structs, specifically "getters"? Here's an example of how they help abstract across different row structs with the same fields.