* threaded parser
[m6w6/ext-psi] / psi.d / errno.psi
1 #include <errno.h>
2
3 #ifdef __GNUC__
4 # ifdef linux
5 function psi\errno() : int {
6 return __errno_location() as to_int(*__errno_location);
7 }
8 # endif /* linux */
9 # ifdef __FreeBSD__
10 function psi\errno() : int {
11 return __error() as to_int(*__error);
12 }
13 # endif /* __FreeBSD__ */
14 #endif /* __GNUC__ */