From: Eyal Farago (eyalfa_at_[hidden])
Date: 2002-04-07 12:25:40
Which is the latest version of shred_ptr? I ahve boost 1.27.0 on my
the following code did not compile:
the error message:
c:\boost_1_27_0\boost\checked_delete.hpp(26) : error C2027: use of
undefined type 'my_class'
-the file and line leads to boost::checked_delete()
When doing the same thing with other 'smart' classes msvc6 usually gives
a warning about deletion of incomplete type...
From: Peter Dimov [mailto:pdimov_at_[hidden]]
Sent: Sunday, April 07, 2002 5:11 PM
Subject: Re: [boost] Circular dependencies and smart pointers
From: "Eyal Farago" <eyalfa_at_[hidden]>
> I believe that this problem can be solved by explicitly defining non
> inlined destructors to your classes, and implementing them in cpp
> that includes the full class definitions.
> I had a similar problem when I used smar pointers to incomplete types
> my classes, what actually happens is that since the d'tor is inlined
> defined implicitly ,its 'code' is generated in the first cpp that
> includes it, and then you get the compiler warning 'deletion of
> incomplete type...' that boost's checked_delete transforms into a
> compile time error.
This is no longer necessary if you are using the latest shared_ptr (but
still the case with scoped_ptr.) If shared_ptr doesn't work with
types then this is a bug (either in shared_ptr or in the compiler ;-) )
Unsubscribe & other changes:
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk