According to Kevin A. Foss:
IMHO, this code is still broken. On a non-DOS platform it tries to pass an integer to a function expecting a cardinal and always returns a type check error and doesn't compile.
Uh - sorry! #-) GPC checks whether the return type of the function matches the expected parameter, and if that's not the case, it tries to pass the function itself as a parameter. It should check whether the return type of the function *is assignment compatible* with the type of the expected parameter ...
I am noting this as a GPC bug report (kevin1.pas).
However one can work around this by letting `GetPID' return a `Cardinal' instead of an `Integer' thus disallowing negative PIDs.
Peter
Dipl.-Phys. Peter Gerwinski, Essen, Germany, free physicist and programmer peter.gerwinski@uni-essen.de - http://home.pages.de/~peter.gerwinski/ [971005] maintainer GNU Pascal [971001] - http://home.pages.de/~gnu-pascal/ [971005]