2018-08-30 07:18:55 -05:00
|
|
|
// run-pass
|
2021-06-11 06:22:13 -05:00
|
|
|
// revisions: x64 x32
|
|
|
|
// [x64]only-x86_64
|
2021-11-04 09:30:23 -05:00
|
|
|
// [x32]only-x86
|
2016-10-25 12:56:36 -05:00
|
|
|
|
2016-01-12 14:21:28 -06:00
|
|
|
#![feature(abi_vectorcall)]
|
|
|
|
|
|
|
|
trait A {
|
|
|
|
extern "vectorcall" fn test1(i: i32);
|
|
|
|
}
|
|
|
|
|
|
|
|
struct S;
|
|
|
|
|
|
|
|
impl A for S {
|
|
|
|
extern "vectorcall" fn test1(i: i32) {
|
|
|
|
assert_eq!(i, 1);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
extern "vectorcall" fn test2(i: i32) {
|
|
|
|
assert_eq!(i, 2);
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
<S as A>::test1(1);
|
|
|
|
test2(2);
|
|
|
|
}
|