Yes, that's pretty much the case.  A lot of those uses were hacks
designed to get around the deficiencies of the old loading model.

Rick

On Wed, Mar 25, 2009 at 2:06 PM, Mark Miesfeld <miesf...@gmail.com> wrote:
> On Wed, Mar 25, 2009 at 10:05 AM, Rick McGuire <object.r...@gmail.com> wrote:
>
>> The users *might* have gone away...there could be references to the
>> package on instances running on other threads.  The timing of when the
>> weak references can be cleared are subject to the dynamics of the
>> garbage collector.  One factor that might result in it not getting
>> cleared immediately upon termination is uninit methods on class
>> instances created from the same package.  It's really just a matter of
>> timing on when that gets cleared.  So if the package manager still has
>> an instance in the cache, it gets used.  The cache entry can
>> potentially get cleared out to prevent a persistent memory leak, but
>> the weak reference will not get cleared at the exact moment the object
>> goes out of scope.  It takes at least one GC cycle (potentially more
>> if uninit methods are involved).
>
> That all makes sense to me Rick.  And, I am far, far, more in favor of
> the current behavior of the package only getting loaded once than the
> old behavior of the package getting loaded over and over.
>
> So, for people using the C / C++ APIs to start the interpreter more
> than once in a single process, the advice would be to not use any
> package files that rely on the code before the directives being
> executed?
>
> --
> Mark Miesfeld
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Oorexx-devel mailing list
> Oorexx-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/oorexx-devel
>

------------------------------------------------------------------------------
_______________________________________________
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel

Reply via email to