[RFC] Consider adding a function to convert error name to errno
Rocket Ma
marocketbd@gmail.com
Fri May 8 09:22:32 GMT 2026
I noticed that in glibc, strerrorname_np(0) returns `0'. If we have
this kind of convention, allow user to convert `0' to errno 0, then we
can not use 0 as error indicator.
Rocket
> * Rocket Ma:
>
> C and POSIX require that all predefined macros have positive values.
> This doesn't mean that there are no implementations that define
> additional errno macros with negative values in some implementations,
> which might include -1. Maybe 0 could be used as the error indicator,
> though.
>
> Thanks,
> Florian
>
More information about the Libc-alpha
mailing list