mirror of
https://github.com/dlang/dmd.git
synced 2025-04-26 13:10:12 +03:00
fix Issue 23411 - ImportC: undefined identifier __builtin_nanf (#15918)
This commit is contained in:
parent
000490465a
commit
e5d742b92e
2 changed files with 5 additions and 0 deletions
|
@ -23,6 +23,7 @@
|
|||
|
||||
#ifndef __APPLE__ // /Applications/Xcode-14.2.0.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/tgmath.h(39): Error: named parameter required before `...`
|
||||
#include <math.h>
|
||||
float x = NAN;
|
||||
#endif
|
||||
|
||||
#ifndef _MSC_VER // setjmp.h(51): Error: missing tag `identifier` after `struct
|
||||
|
|
|
@ -53,6 +53,10 @@ version (CRuntime_Microsoft)
|
|||
|
||||
version (DigitalMars)
|
||||
{
|
||||
immutable float __nan = float.nan;
|
||||
|
||||
float __builtin_nanf()(char*) { return float.nan; }
|
||||
|
||||
double __builtin_inf()() { return double.infinity; }
|
||||
float __builtin_inff()() { return float.infinity; }
|
||||
real __builtin_infl()() { return real.infinity; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue