mirror of
https://github.com/vlang/v.git
synced 2025-09-16 10:57:25 -04:00
tests: add 'aligned_attr_gcc_windows.vv' for gcc (#20870)
This commit is contained in:
parent
50e271a77e
commit
d198a89897
@ -255,6 +255,12 @@ fn should_skip(relpath string) bool {
|
||||
return true
|
||||
}
|
||||
}
|
||||
$if msvc {
|
||||
if relpath.contains('_gcc_windows.vv') {
|
||||
eprintln('> skipping ${relpath} on msvc')
|
||||
return true
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if relpath.contains('_windows.vv') {
|
||||
eprintln('> skipping ${relpath} on !windows')
|
||||
|
13
vlib/v/gen/c/testdata/aligned_attr_gcc_windows.c.must_have
vendored
Normal file
13
vlib/v/gen/c/testdata/aligned_attr_gcc_windows.c.must_have
vendored
Normal file
@ -0,0 +1,13 @@
|
||||
|
||||
struct main__Test {
|
||||
int a;
|
||||
} __attribute__((aligned (8)));
|
||||
|
||||
struct main__Test2 {
|
||||
int a;
|
||||
int b;
|
||||
} __attribute__((aligned (16)));
|
||||
|
||||
union main__Test3 {
|
||||
int a;
|
||||
} __attribute__((aligned (8)));
|
0
vlib/v/gen/c/testdata/aligned_attr_gcc_windows.out
vendored
Normal file
0
vlib/v/gen/c/testdata/aligned_attr_gcc_windows.out
vendored
Normal file
17
vlib/v/gen/c/testdata/aligned_attr_gcc_windows.vv
vendored
Normal file
17
vlib/v/gen/c/testdata/aligned_attr_gcc_windows.vv
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
// vtest vflags: -cc gcc -os windows
|
||||
|
||||
@[aligned:8]
|
||||
struct Test {
|
||||
a int
|
||||
}
|
||||
|
||||
@[aligned:16]
|
||||
struct Test2 {
|
||||
a int
|
||||
b int
|
||||
}
|
||||
|
||||
@[aligned:8]
|
||||
union Test3 {
|
||||
a int
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user