[fpc-devel] Some details on BeginThread problem

Robert Reimiller certgrps at certsoft.com
Fri Sep 8 21:44:41 CEST 2006


On Fri, 08 Sep 2006 11:18:49 -0000, Jonas Maebe  
<jonas.maebe at elis.ugent.be> wrote:

> You are using the default FPC mode as opposed to Delphi or MacPas
> mode (which Xcode template are you using? They all set macpas mode by
> default). Therefore the compiler interprets your use of "libthread"
> as a function call, and expects parameters after it. Either compile
> with -Sd or add {$mode delphi} at the top of your program, or change
> "addr(libthread)" into "@libthread" (it's interesting that addr
> behaves differently from @ though, I didn't know that).

I'm using objfpc mode. Changing addr(libthread) into @libthread solved the  
problem.
I should have thought of that since I had the same problem with getting the
address of a callback procedure. It now all compiles, now for the  
debugging......

Thanks,

Bob



More information about the fpc-devel mailing list