Return By Value

Return a brand new object or primitive value, a clone/copy of the object/primitive you are returning.

For instance, in C++,

 struct RECT { int x, y, width, height };

...

RECT bounds; RECT getBounds() { return bounds; }

Compare ReturnByReference.


CategoryCpp


EditText of this page (last edited March 1, 2010) or FindPage with title or text search