> We implemented an optimized (for in polygon search) R-tree data structure for the lookups.
I wouldn't be surprised that due to the lack of generics in golang, this approach was less feasible.
I wouldn't be surprised that due to the lack of generics in golang, this approach was less feasible.
Also, how does it make testing harder?
You can't typecheck the generic itself. Especially conversions could be really hard with them.
(I love generics, still this somewhat aweful). Currently Converting Generics between Scala and Java is totally Ugly.
(disclaimer: i think that lack of generics in Go is a mistake)
Go generate, for example, brings me back memories of a time C++ compilers used pre-processor magic for generic programming, around 1994 or so.
Something like
#define Type1 my nice type1 definition
#include <generic-list.h>
#undef Type1
#define Type1 my nice type2 definition
#include <generic-list.h>
ListType1 ...
ListType2 ...