Boost logo

Boost Users :

From: Frank Birbacher (bloodymir.crap_at_[hidden])
Date: 2008-05-18 17:42:48


Hi!

Noah Roberts schrieb:
> Actually, I think you are correct on that. A temporary will only
> survive into the function call if you are accepting a const& afaik. If
> you are accepting a const reference then whatever is passed in will be
> bound to that object and is guaranteed to survive. Otherwise no.

All of my knowledge tells me: you are *not* in trouble here.

But at least 10 years ago it was unclear, as this article from
comp.std.c++ shows:
http://groups.google.com/group/comp.std.c++/msg/3fbd47d85ab1e47d

Regards, Frank


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net