Multi threading support was Re: [fpc-devel] Russian locale information not compatible withFPClocale variables
Michael Schnell
mschnell at lumino.de
Thu Jul 31 12:01:49 CEST 2008
>
> Yes. Acutally only one thread can enter the class.
Hmmm.
In my mind, a "class" is meant tor managing code and variables, while a
thread is for managing execution contexts.
These two concepts don't have anything to do with each other: a class
and an instance of same can be "associated with" or "executed by"
several threads, a thread can execute several instances of a class.
E.g. Even the standard "TThread" defines a single thread (this is how
it's code is implemented) , but the some functions and variables of same
are/can be used by the thread, by another thread or by both.
Now you suggest that all procedures an instance of this kind of class
are protected and thus thread-safe by definition.
This might be a really good thing, but needs some decent explanation as
the bundling of code/variable administration and thread context
administration is not a "natural" self-explaining concept.
-Michael
More information about the fpc-devel
mailing list