hyln9 / ikarus

Optimizing incremental native-code compiler for R6RS scheme. This is a forked repository.
https://launchpad.net/ikarus
Other
5 stars 0 forks source link

errno setter is needed #246

Open hyln9 opened 10 years ago

hyln9 commented 10 years ago

There are functions like "readdir()" for which setting "errno" to zero before the call is the only way to distinguish between error conditions and other events. So an "errno" setter is needed (Larceny implements it, Ypsilon not yet).

Launchpad Details: #LP313155 Marco Maggi - 2009-01-02 04:20:28 -0500

hyln9 commented 10 years ago

I have implemented a setter by using the FFI to call the function "__errno_location()", which returns the pointer to the (thread specific) "errno" variable, and then using the poker for "int".

From my limited testing so far it works.

Launchpad Details: #LPC Marco Maggi - 2009-01-05 16:56:12 -0500