September 23 [Issue 24779] New: ImportC: undefined identifier `_Float16` | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=24779 Issue ID: 24779 Summary: ImportC: undefined identifier `_Float16` Product: D Version: D2 Hardware: All OS: Mac OS X Status: NEW Keywords: ImportC Severity: normal Priority: P1 Component: dmd Assignee: nobody@puremagic.com Reporter: dave287091@gmail.com MacOS’s math.h has been updated for the new OS version and new SDK and is now unconditionally using the _Float16 type (which I think was standardized with C23). math.h now has these declarations: extern _Float16 __fabsf16(_Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __hypotf16(_Float16, _Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __sqrtf16(_Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __ceilf16(_Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __floorf16(_Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __rintf16(_Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __roundf16(_Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __truncf16(_Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __copysignf16(_Float16, _Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __nextafterf16(_Float16, _Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __fmaxf16(_Float16, _Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __fminf16(_Float16, _Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); extern _Float16 __fmaf16(_Float16, _Float16, _Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0)); ImportC is unable to parse these. You can work around it by #defining _Float16 to any other type to get things to compile and just don’t call those functions. -- |
Copyright © 1999-2021 by the D Language Foundation