www.digitalmars.com         C & C++   DMDScript  

c++ - And kudos to Walter, at least two bugs were boost bugs

reply dan <dan_member pathlink.com> writes:
that none of the other compilers cought... like feeding a const ref to an
auto_ptr... figures!

Next step, regression tests...
Dec 11 2003
parent reply "Matthew Wilson" <matthew.hat stlsoft.dot.org> writes:
 that none of the other compilers cought... like feeding a const ref to an
 auto_ptr... figures!

Can you be specific? There are several different (aged) auto_ptr implementations, so it may not be the case that the others are in error
Dec 12 2003
parent reply dan <dan_member pathlink.com> writes:
In article <brdlju$13fn$1 digitaldaemon.com>, Matthew Wilson says...
 that none of the other compilers cought... like feeding a const ref to an
 auto_ptr... figures!

Can you be specific? There are several different (aged) auto_ptr implementations, so it may not be the case that the others are in error

Well, maybe I'm missing something, but my understanding is that auto_ptr must be able to delete the object that it manages. If so, it couldn't take a const ref, unless it then casts away the constness in order to delete it. But your very asking this makes me suspect that indeed I must be missing something... dan
Dec 12 2003
parent reply "Matthew Wilson" <matthew.hat stlsoft.dot.org> writes:
It's legal to delete something that is const.

Deletion is not class as modifying it. <G>

"dan" <dan_member pathlink.com> wrote in message
news:brdp3n$18p0$1 digitaldaemon.com...
 In article <brdlju$13fn$1 digitaldaemon.com>, Matthew Wilson says...
 that none of the other compilers cought... like feeding a const ref to



 auto_ptr... figures!

Can you be specific? There are several different (aged) auto_ptr implementations, so it may not be the case that the others are in error

Well, maybe I'm missing something, but my understanding is that auto_ptr

 able to delete the object that it manages. If so, it couldn't take a const

 unless it then casts away the constness in order to delete it.
 But your very asking this makes me suspect that indeed I must be missing
 something...

 dan

Dec 12 2003
parent dan <dan_member pathlink.com> writes:
In article <brdupq$1ml2$1 digitaldaemon.com>, Matthew Wilson says...
It's legal to delete something that is const.

Deletion is not class as modifying it. <G>

Doh! I think I'd heard this before, but it totally left my mind without a trace; thank you! Okay Walter, I must retract my earlier retraction, but the kudos stay .. ;) dan
Dec 12 2003