On 21 Dec 2010, at 14:59, michael.vancann...@wisa.be wrote:
On Tue, 21 Dec 2010, Mattias Gaertner wrote:
What about using a
threadvar CurrentThread: Thread;
?
TThread could set this in the constructor.
This could be done, but will give errors for externally created
threads.
And for threads created with BeginThread.
But you can easily do this for your own thread objects.
I also think that's the best solution. If that's not enough, then
doing it in tthread won't be enough either (unless you only support
applications that exclusively use tthread-based threads).
Jonas
_______________________________________________
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal