Brief material on C++ object-lifetime management and on passing and returning values/references

Posted by dsign on Programmers See other posts from Programmers or by dsign
Published on 2012-11-16T10:00:40Z Indexed on 2012/11/16 11:13 UTC
Read the original article Hit count: 203

Filed under:
|

I was wondering if anybody can point to a post, pdf, or excerpt of a book containing the rules for C++ variable life-times and best practices for passing and returning function parameters. Things like when to pass by value and by reference, how to share ownership, avoid unnecessary copies, etc. This is not for a particular problem of mine, I've been programming in C++ for long enough to know the rules by instinct, but it is something that a lot of newcomers to the language stumble with, and I would be glad to point them to such a thing.

© Programmers or respective owner

Related posts about c++

Related posts about reference