> '?' indeed! I am fascinated! What does yield do exactly... presumably it
> returns a result from the function without closing down that instance of
> the function? Amazing concept.

I suspect - given the word "DOS" in some of the code, it allows a DOS
event loop to continue in a single threaded co-operative multitasking
environment. A bit like Application.ProcessMessages in Delphi or
Application.DoEvents() in DotNet. You can probably do other things at the
same time, but Yield says this to me (maybe my old Mac programming hat as
the Toolbox has a similar API.) If so, it's probably a little redundant
now and use of threads could get around the problem (or even using the
Application object from Lazarus API to implement the
"processmessages"/yield part?)

_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to