Hacker News new | past | comments | ask | show | jobs | submit login

I really dislike languages which decide to bless some special data-structures, but then won't let me add my own generic data structures.

Of course, I really love data structures, so I can understand other people who just want to get on with things, and are happy to slightly abuse some built-in data structures to get most of the way there.




Go doesn't stop you from building datastructures, actually is really nice for building datastructures.

It simply doesn't provide a simple way to build some kinds of generic datastructures, but when the ones provided by the language are not enough it usually means your problem is specialized enough that a custom datastructure is best anyway, and Go makes that pleasant and easy.

And then there are interfaces, which are a kind of "generics" of their own.


I don't like the special treatment for builtin data structures either. But if the alternatives are ending up in a mental institution (C++ templates) or in a Potemkin village (Java), I'd rather live with this inconsistency for a while.

Maybe (hopefully!) these are not the only alternatives.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: