[fpc-pascal] Thread Variables Initial Values

African Wild Dog paintedlycaon at gmail.com
Fri Mar 17 16:28:41 CET 2017


The documentation is not clear about the initial values of thread variables:

*"If threads are used then a copy is made for each thread (including the
main thread). Note that the copy is made with the original value of the
variable, not with the value of the variable at the time the thread is
So, if i declare a threadvar:

  MyObject: TObject;

What will be the initial value of the variable when each thread uses its
copy for the first time?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20170317/c2224757/attachment.html>

More information about the fpc-pascal mailing list