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

Code bloat, at least _compiled_ code bloat, tends to be less on an issue with trivial accessors in C++ since they are generally inlined, but it does add a lot ()s. For non-trivial accessors, yeah, you can inline a lot of copies of that logic.

Vector v1(v2.getX(), v2.getY(), v2.getZ()); vs Vector v1(v2.x, v2.y, v2.z);




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

Search: