[all-commits] [llvm/llvm-project] 84b0f0: [clang-cl] Don't add implicit NoBuiltinAttr to del...

VScigolevs via All-commits all-commits at lists.llvm.org
Fri Dec 13 03:24:53 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 84b0f0145887bbfe49fd4dc85490b14108a72cee
      https://github.com/llvm/llvm-project/commit/84b0f0145887bbfe49fd4dc85490b14108a72cee
  Author: VScigolevs <vladimirs.scigolevs at zimperium.com>
  Date:   2024-12-13 (Fri, 13 Dec 2024)

  Changed paths:
    M clang/lib/Sema/SemaAttr.cpp
    A clang/test/SemaCXX/msvc-pragma-function-no-builtin-attr.cpp

  Log Message:
  -----------
  [clang-cl] Don't add implicit NoBuiltinAttr to deleted or defaulted functions (#119719)

In Clang `#pragma function` is implemented by adding an implicit
NoBuiltin Attribute to all function definitions after the pragma. This
(wrongly) includes also defaulted or deleted functions, which results in
the error, shown in #116256.

As this attribute has no effect on the deleted or defaulted functions,
this commit fixes the previously mentioned issue by simply not adding
the attribute in such cases.

Fixes #116256



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list