5 ms·
Just write an implementation of map/reduce/filter for every type in your go program!
by smadge 7y ago
Just write an implementation of map/reduce/filter for every type in your go program!
- smadge 7y agoMaybe you could create some text macros to simplify the process, and then run a preprocessor on your program, and then.... uh oh.
- jnwatson 7y agoYou joke, but source code generation is the standard way to generics in go. They even have some standard hooks for it in the build system.
- gray_-_wolf 7y agoI still consider weird that results of go generate are supposed to be committed. Since when does generated code belong to the repository :/