[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: RFC: Proper destruction of static data?
From:       Stephan Kulow <coolo () kde ! org>
Date:       2000-06-27 19:37:13
[Download RAW message or body]

David Faure wrote:
> 
> On Tue, Jun 27, 2000 at 09:27:08PM +0200, Harri Porten wrote:
> > Werner Trobin wrote:
> > >
> > > We #define KSTATIC static and let some magic tool look
> > > for KSTATIC in the sources. It extracts all the variable
> > > names (only static pointers to objects are allowed) and
> > > creates a "clean up" function. This function deletes all
> > > the objects when the lib gets unloaded...
> > >
> > > Am I completely wrong? Do I miss something important?
> > > Comments, suggestions, flames...?
> >
> > Sounds very interesting. My comment/suggestion: order of destruction can
> > be quite important. Therefore, it has to be well defined and documented.
> 
> Right.... Then what about a "user-defined callout (per library)"
> where the library's developer does a proper destruction, instead of having
> it done automatically ? Hmm, more complex for the developer than just K_STATIC.
> 
I would say if you use static objects, you don't care for the order of
construction,
so I don't see a point in having the destruction ordered

Greetings, Stephan

-- 
... but you ain't had mine

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic