[Issue 22721] importC: some gnu builtins are rejected

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Feb 8 18:02:16 UTC 2022


https://issues.dlang.org/show_bug.cgi?id=22721

duser at airmail.cc changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
                 CC|                            |duser at airmail.cc
         Resolution|FIXED                       |---

--- Comment #3 from duser at airmail.cc ---
slight issue with the fix:

"__builtin_assume_aligned" in the linked GNU docs is different from the
"__builtin_assume" mentioned in the issue, the actual one is documented here:

https://releases.llvm.org/13.0.0/tools/clang/docs/LanguageExtensions.html#builtin-assume

its D implementation would be

  void __builtin_assume()(lazy bool) { return; }

the assume builtin added in the PR has the signature of
__builtin_assume_aligned
from the docs but is named __builtin_assume, it should be renamed to add
_aligned

--


More information about the Digitalmars-d-bugs mailing list