www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 22535] New: ImportC: gcc/clang math intrinsics are rejected.


          Issue ID: 22535
           Summary: ImportC: gcc/clang math intrinsics are rejected.
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: dave287091 gmail.com

math.h on macOS uses the following gcc/clang builtins:


A much larger list of these builtins are described here:

It’s common for this header to be directly or transitively included. It is
possible at least on macOS to avoid these if you preprocess with the
-ffast-math flag as then it will counterintuitively declare extern versions of
functions like isfinite instead of defining them as inline functions using
these intrinsics.

I don’t know if we want dmd to actually recognize all of these intrinsics.

Nov 21 2021