llvm-project/clang/test/SemaCXX/m68k-rtdcall.cpp
Min-Yih Hsu fd4f96290a [Clang][M68k] Add Clang support for the new M68k_RTD CC
This patch adds `CC_M68kRTD`, which will be used on function if either
`__attribute__((m68k_rtd))` is presented or `-mrtd` flag is given.

Differential Revision: https://reviews.llvm.org/D149867
2023-10-15 16:13:43 -07:00

15 lines
226 B
C++

// RUN: %clang_cc1 -triple m68k-linux-gnu -fsyntax-only %s
class A {
public:
void __attribute__((m68k_rtd)) member() {}
};
void test() {
A a;
a.member();
auto f = [](int b) __attribute__((m68k_rtd)) {};
f(87);
};