LibC: Add ELAST errno macro

The ELAST macro is used on many systems to refer to the largest possible
valid errno value. LLVM's libc++ uses errno values of ELAST+1 and
ELAST+2 internally, and defines an arbitrary fallback value for
platforms which don't have the macro. This means that it's possible for
their internal errno numbers could coincide with values we actually use,
which would be a very bad thing.
This commit is contained in:
Daniel Bertalan 2021-10-02 14:35:15 +02:00 committed by Linus Groh
parent b5fcb10493
commit 685045176b

View file

@ -160,3 +160,4 @@ enum ErrnoCode {
};
#define EWOULDBLOCK EAGAIN
#define ELAST EMAXERRNO