[lld][WebAssembly] Reinstate mistakenly disabled test. NFC
[llvm-project.git] / clang / test / SemaCXX / attr-regparm.cpp
blob92e651bd5eebdc985513a1e10f5e20a1a6daa766
1 // RUN: %clang_cc1 -fsyntax-only -verify -triple x86_64-pc-linux-gnu %s
2 // RUN: %clang_cc1 -fsyntax-only -verify -triple i686-apple-darwin10 %s
4 // PR7025
5 struct X0 {
6 void __attribute__((regparm(3))) f0();
7 void __attribute__((regparm(3))) f1();
8 void __attribute__((regparm(3))) f2(); // expected-note{{previous declaration is here}}
9 void f3(); // expected-note{{previous declaration is here}}
12 void X0::f0() { }
13 void __attribute__((regparm(3))) X0::f1() { }
14 void __attribute__((regparm(2))) X0::f2() { } // expected-error{{function declared with regparm(2) attribute was previously declared with the regparm(3) attribute}}
15 void __attribute__((regparm(2))) X0::f3() { } // expected-error{{function declared with regparm(2) attribute was previously declared without the regparm attribute}}