This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Binding a temporary to a const reference


I wrote:
>  >> While I believe you are correct in saying that g++ is wrong in this case,
>  >> the protection rule is independent of whether or not the copy constructor
>  >> is actually called.
> 
>  > Yes, I'm aware of that. (Seems to me there used to be a bug in g++
>  > regarding that, didn't there?)

Jason writes:
> g++ started enforcing this rule recently, but then the rule itself is
> somewhat recent.

Congrats!  This is the first time I've observed g++ being more anal-retentive 
than HP's aCC, which accepts the code. :-)



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]