Skip to content
This repository was archived by the owner on Oct 12, 2022. It is now read-only.

Commit 1c8051b

Browse files
author
Diederik de Groot
committed
Fix core.stdc.errno
1 parent aa4be02 commit 1c8051b

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/core/stdc/errno.d

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,14 @@ else version (FreeBSD)
102102
}
103103
else version (DragonFlyBSD)
104104
{
105-
pragma(mangle, "errno") extern int __errno;
106-
ref int errno() { return __errno;}
105+
extern (C)
106+
{
107+
pragma(mangle, "errno") int __errno;
108+
ref int __error() {
109+
return __errno;
110+
}
111+
alias errno = __error;
112+
}
107113
}
108114
else version (CRuntime_Bionic)
109115
{

0 commit comments

Comments
 (0)