You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It would be nice to have an easy way to generate collections of strings, ints etc.
Even though there is only a small set of Go primitive types, generating the collections for them using gen would be a bit better than hand-coding because future developments of gen could be made use of with very little effort (just run gen again).
The text was updated successfully, but these errors were encountered:
Thanks, I’ve been thinking about this. This wouldn’t actually require codegen, it could just be an import, since it’s a finite set of known types. I’ll get to it after I’ve gotten the projection bits stable.
@rickb777 The recent changes implement this, so long as it’s your type, along the lines of type MyType int.
Doing this in a general sense for all primitives would still require the creation of some sort of alias type, like type Ints []int.
For purposes of gen, I’m happy with the current approach but feel free to tell me about what you’d like a more general solution to look like, maybe it’s an idea for separate project.
It would be nice to have an easy way to generate collections of strings, ints etc.
Even though there is only a small set of Go primitive types, generating the collections for them using
gen
would be a bit better than hand-coding because future developments ofgen
could be made use of with very little effort (just rungen
again).The text was updated successfully, but these errors were encountered: