Hi Przemek

Francesco Saverio Giudice wrote:
> 
> It could be useful in both way IMO, so it could be interesting if it can 
> be used as auto-cloned in standard way and work referenced if BYREF (or 
> similar name) option is defined.
> 
> thread BYREF static aFld := { { '', 0 } }
> 

I support Francesco's viewpoint.

THREAD STATIC should alway create always new copy.
BYREF THREAD STATIC should behave as current.

I have a very large mini ERP solution adoptable to 
different industries. I get it working on Xbase++ few years back 
with MT modal. Though I devised the method to keep arrays 
different threads but then those consumed a lot of memory 
as ThreadID() ever points to incremented number ( perfectly all right )
and arry references kept in static array referenced by ThreadID() could 
never be released at the termination of a thread. 

So I tried with THREAD STATIC approach and come up with above issue.

As THREAD STATICS are bound to be released automatically once 
the thread is terminated, I would like to implement this as I assume it
should.
Though I can reuse Xbase++ methodology which I do not want to.

Regards
Pritpal Bedi
prefer

-- 
View this message in context: 
http://www.nabble.com/File-wide-THREAD-STATICS-%3A-behaving-differently-tp21049014p21060319.html
Sent from the Harbour - Dev mailing list archive at Nabble.com.

_______________________________________________
Harbour mailing list
[email protected]
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to