Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

This is one advantage of C++ (and C, and others) which I didn't really realise until fairly recently. Because I have a good quality compiler, I do not have to worry about little functions.

If I want to make a class with a single int member, and a bunch of member functions, I can trust that will, in most cases, compile away to be just as efficient as a raw int and inline code. It is very liberating to not have to worry about the efficiency of creating another function.



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

Search: