Ticket #1564 (closed feature: done)
expose a getpid library function for Rakudo $*PID and other languages
|Reported by:||mberends||Owned by:||NotFound|
|Severity:||medium||Keywords:||process ID pid getpid|
Please enable language implementations to read the ID of the running Parrot process. Coke++ implemented it in partcl with an "evil" workaround:
In Windows the lib should not be null, it should get the loadlib 'kernel32' result, and the function name is '_getpid' instead of 'getpid'.
The idea was discussed during about an hour from http://irclog.perlgeek.de/parrot/2010-04-19#i_2242886
The Rakudo file src/cheats/setup-io.pm intends to use this function. In the meantime, it may get by with a workaround similar to the one in partcl.