Re: [Boost-users] Error:" Non-const function called for const object" on Sun CC while using boost::multi_index::multi_index_container
De: Alexander Vinokur [Alexander.Vinokur@amdocs.com] Enviado el: martes, 07 de octubre de 2008 18:28 Para: boost-users@lists.boost.org CC: JOAQUIN M. LOPEZ MUÑOZ Asunto: RE: Error:" Non-const function called for const object" on Sun CC while using boost::multi_index::multi_index_container
Joaquin, thank you.
Here code I compiled.
// --- File foo3.cpp --- [...] const Bar* p4 = new Bar; p4->~Bar(); // line 19: Error: Non-const function Bar::__SLIP.DELETER__A() called for const object.
OK, seems like the bug we were after, if only in a slightly different guise (deleting a const T* works, but directly calling ~T() on a const object does not). Alex, can you do the following? Please try replacing the /boost/detail/allocator_utilities.hpp file in your local Boost copy with the attached file and rebuild the multi_index_container code that was failing. Does this fix it? If so, I'll commit this version into the trunk so that it'll be available in Boost 1.38 (though you can use it now with your local Boost copy, of course). Joaquín M López Muñoz Telefónica, Investigación y Desarrollo
participants (1)
-
JOAQUIN M. LOPEZ MUÑOZ