by MW Ron <mwron@[EMAIL PROTECTED]
>
May 27, 2004 at 09:47 AM
In article <2hlrtaFeclmrU1@[EMAIL PROTECTED]
>,
Tobias Stoeger <not.for.reply@[EMAIL PROTECTED]
> wrote:
Thanks for the clarification. I'll pass this on to engineering for
their thoughts and enter it into a suggestion database.
Ron
>I don't know if you are familiar to symbian os patterns/idioms, so I'll
>briefly
>explain the CleanupStack - in my own words ;-)
>
>The CleanupStack is a class that offers static methods to tem****arily
>put pointers to objects on a stack (last in - first out).
>
>Before your code enters a section that may fail you have to put(push)
pointers
>to
>your heap allocated objects on this stack.
>
>If your programm/code fails (i.e. a method leaves) then the
Cleanup-Framework
>will garantie that all objects you former put(pushed) on the CleanupStack
will
>be
>cleaned up and so there are no memory leaks.
>(BTW: In Java the garbage collector will do this job for you.)
>If no leave occur then you have to remove(pop) your object pointers from
the
>CleanupStack.
>If you pop wrong objects (only in debug mode) then the programm panics
>"E32USER-CBase Panic 90" or if at the end of execution are still objects
on
>it.
>Both states are facts that your code leaks memory.
>
>I think the debugger should to analyse the memory of a stack member of
the
>class CleanupStack where all pointers to the cleanup objects are stored
>and show the content in the debugger view, like a variable in the
>debugger view ("show as...").
>
>Maybe it's best if you to talk to one of the symbian guys before
implementing
>this feature.
>
>The great benefit would be, that one could inspect the order and kind of
>objects actually placed on the CleanupStack.
>
>BTW: Thanks for the CW Quick Reference!
--
Metrowerks, one of the world's top 100 companies and influencers
in the software development industry. - SD Times May 2004
http://www.sdtimes.com/2004sdt100.htm
Metrowerks, maker of CodeWarrior
Ron Liechty - MWRon@[EMAIL PROTECTED]
- http://www.metrowerks.com