[Larceny-users] Re

Marco Maggi marco.maggi-ipsu at poste.it
Fri Jan 2 04:12:38 EST 2009


"William D Clinger" wrote:
> Peter Keller wrote:
>> "No function in this volume of IEEE Std
>> 1003.1-2001 shall set errno to 0."
>>
>> Just to keep that in mind....
>
> Right.  So, quoting more from that same link,
> the paradigm is:
>
>   An application that needs to examine the
>   value of errno to determine the error should
>   set it to 0 before a function call, then
>   inspect it before a subsequent function call.

"Peter Keller" wrote:
> The question becomes, if someone writes a scheme
> layer wrapping the libc layer, then do they
> violate POSIX semantics in the context of the
> scheme layer if their wrapper sets errno to zero
> before calling the glibc function associated with
> it?

I dunno if there is value in letting the POSIX
semantics filter through a Scheme layer, what
I know is that there are functions, like
"readdir()", for which setting "errno" to zero
before the call is the only way to distinguish
an error condition from another event.

So setting "errno" is a mandatory feature.
-- 
Marco Maggi

"Now feel the funk blast!"
Rage Against the Machine - "Calm like a bomb"






More information about the Larceny-users mailing list