[clang] [clang] Fix '__cdecl' CC is not supported for this target (PR #74932)

Richard Dzenis via cfe-commits cfe-commits at lists.llvm.org
Sat Dec 9 05:46:53 PST 2023


https://github.com/RIscRIpt created https://github.com/llvm/llvm-project/pull/74932

Fixes regression introduced in b3e6ff331925dde24a4707452d657da0fdf7f588

    .---command stderr------------
    | error: 'supported-warning' diagnostics seen but not expected:
    |   File C:\buildbot\as-builder-1\x-armv7l\llvm-project\clang\test\SemaCXX\ms-constexpr-new.cpp Line 7: '__cdecl' calling convention is not supported for this target
    | 1 error generated.
    `-----------------------------

>From e16ec1411f7f813f7c1b60fd9671db116b083d02 Mon Sep 17 00:00:00 2001
From: Richard Dzenis <dzenis at richard.lv>
Date: Sat, 9 Dec 2023 15:44:54 +0200
Subject: [PATCH] [clang] Fix '__cdecl' CC is not supported for this target

Fixes regression introduced in b3e6ff331925dde24a4707452d657da0fdf7f588

    .---command stderr------------
    | error: 'supported-warning' diagnostics seen but not expected:
    |   File C:\buildbot\as-builder-1\x-armv7l\llvm-project\clang\test\SemaCXX\ms-constexpr-new.cpp Line 7: '__cdecl' calling convention is not supported for this target
    | 1 error generated.
    `-----------------------------
---
 clang/test/SemaCXX/ms-constexpr-new.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/clang/test/SemaCXX/ms-constexpr-new.cpp b/clang/test/SemaCXX/ms-constexpr-new.cpp
index 05ee5c5b4e154a..30567740b2ecbb 100644
--- a/clang/test/SemaCXX/ms-constexpr-new.cpp
+++ b/clang/test/SemaCXX/ms-constexpr-new.cpp
@@ -4,7 +4,7 @@
 
 [[nodiscard]]
 [[msvc::constexpr]] // unsupported-warning {{unknown attribute 'constexpr' ignored}}
-inline void* __cdecl operator new(decltype(sizeof(void*)), void* p) noexcept { return p; }
+inline void* operator new(decltype(sizeof(void*)), void* p) noexcept { return p; }
 
 namespace std {
   constexpr int* construct_at(int* p, int v) {



More information about the cfe-commits mailing list