master
1#ifndef _ERRNO_H
2#define _ERRNO_H
3
4#ifdef __cplusplus
5extern "C" {
6#endif
7
8#include <features.h>
9
10#ifdef __wasilibc_unmodified_upstream /* Use alternate WASI libc headers */
11#include <bits/errno.h>
12
13#ifdef __GNUC__
14__attribute__((const))
15#endif
16int *__errno_location(void);
17#define errno (*__errno_location())
18#else
19#include <__errno.h>
20#include <__errno_values.h>
21#endif
22
23#ifdef _GNU_SOURCE
24extern char *program_invocation_short_name, *program_invocation_name;
25#endif
26
27#ifdef __cplusplus
28}
29#endif
30
31#endif
32