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

What you say is somewhat true most of the time when you are writing an application. However, when I am writing a library I have far less control over situations where functions in that library will get called. So it makes sense to make the library lean and lacking obvious bloats, or at least make efficient code paths possible without forcing the application programmer to indulge in excessive verbosity. This makes the library more broadly usable.

As an application developer its a big pain to realize that the library that you have built your application around now needs to be incised out for performance reasons. In theory, if you design your interface well one can switch out libraries, but it is rarely as clean as what theory claims. Interfaces set, if not in stone, at least in in loose concrete, the data-structures that are convenient to use.

EDIT: I hasten to add that I am not complaining about the library, far from it.




This:

> it makes sense to make the library lean and lacking obvious bloats, or at least make efficient code paths possible without forcing the application programmer to indulge in excessive verbosity.

Does not apply to these people:

> It's hard enough teaching people to avoid inefficiency when it's right there in front of them, and harder still when you encapsulate inefficiency in a pretty package.

who, by definition, are not experienced enough to write code that is sufficiently lean and lacking obvious bloat, or at least make efficient code paths possible. If they were, then they won't have a problem with the pretty package either.


Just in the remote case you thought so, I am not the one you quoted in your second quote. I upvoted anyway.


Oh, I know - it was from the post which you replied to.

I only wanted to point out that in the context of the comment you replied to, I didn't feel that those were the people who should be worrying about optimised code.




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

Search: