Skip to content

Commit f722c6e

Browse files
committed
refacto(tests): moved folder and combined test files when possible
1 parent b969498 commit f722c6e

7 files changed

+51
-68
lines changed

clang/test/Driver/windows-Wpadded-alignas.cpp

-12
This file was deleted.

clang/test/Driver/windows-Wpadded-anonymous-bitfield.cpp

-12
This file was deleted.

clang/test/Driver/windows-Wpadded-derived-struct.cpp

-13
This file was deleted.

clang/test/Driver/windows-Wpadded-union.cpp

-19
This file was deleted.

clang/test/Driver/windows-Wpadded.cpp

-12
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
// RUN: %clang_cc1 -triple x86_64-windows-msvc -fsyntax-only -verify -Wpadded %s
2+
3+
struct __attribute__((ms_struct)) BitfieldStruct { // expected-warning {{padding size of 'BitfieldStruct' with 3 bytes to alignment boundary}}
4+
char c : 1;
5+
int : 0; // expected-warning {{padding struct 'BitfieldStruct' with 31 bits to align anonymous bit-field}}
6+
char i;
7+
};
8+
9+
int main() {
10+
BitfieldStruct b;
11+
}
+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
// RUN: %clang_cc1 -triple x86_64-windows-msvc -fsyntax-only -verify -Wpadded %s
2+
// RUN: %clang_cc1 -triple x86_64-linux-gnu -fsyntax-only -verify -Wpadded %s
3+
4+
struct __attribute__((ms_struct)) Foo { // expected-warning {{padding size of 'Foo' with 3 bytes to alignment boundary}}
5+
int b : 1;
6+
char a; // expected-warning {{padding struct 'Foo' with 31 bits to align 'a'}}
7+
};
8+
9+
struct __attribute__((ms_struct)) AlignedStruct { // expected-warning {{padding size of 'AlignedStruct' with 4 bytes to alignment boundary}}
10+
char c;
11+
alignas(8) int i; // expected-warning {{padding struct 'AlignedStruct' with 7 bytes to align 'i'}}
12+
};
13+
14+
15+
struct Base {
16+
int b;
17+
};
18+
19+
struct Derived : public Base { // expected-warning {{padding size of 'Derived' with 3 bytes to alignment boundary}}
20+
char c;
21+
};
22+
23+
union __attribute__((ms_struct)) Union {
24+
char c;
25+
long long u;
26+
};
27+
28+
struct __attribute__((ms_struct)) StructWithUnion { // expected-warning {{padding size of 'StructWithUnion' with 6 bytes to alignment boundary}}
29+
char c;
30+
int : 0;
31+
Union t; // expected-warning {{padding struct 'StructWithUnion' with 7 bytes to align 't'}}
32+
short i;
33+
};
34+
35+
int main() {
36+
Foo f;
37+
AlignedStruct a;
38+
Derived d;
39+
StructWithUnion swu;
40+
}

0 commit comments

Comments
 (0)