Logo
Explore Help
Register Sign In
rust-lang/rust
1
0
Fork 0
You've already forked rust
Code Issues Pull Requests Actions 1 Packages Projects Releases Wiki Activity
Files
55b6f649024b372af901b3412a6d36c4284ccf3d
rust/tests/ui/extern/extern-thiscall.rs

24 lines
294 B
Rust
Raw Normal View History

Add `// run-pass` annotations to all the tests under `ui/run-pass/`. (I may have accidentally added it to some auxilliary crates as well; my emacs-macro-based methodology was pretty crude.)
2018-08-30 14:18:55 +02:00
// run-pass
Fix tests using `only-i686` to use the correct `only-x86` directive We translate `i686` to `x86` which means tests marked as `only-i686` never ran. Update those tests to use `only-x86`.
2021-11-04 10:30:23 -04:00
// only-x86
add thiscall calling convention support This support is needed for bindgen to work well on 32-bit Windows, and also enables people to begin experimenting with C++ FFI support on that platform. Fixes #42044.
2017-05-17 09:40:46 -04:00
trait A {
extern "thiscall" fn test1(i: i32);
}
struct S;
impl A for S {
extern "thiscall" fn test1(i: i32) {
assert_eq!(i, 1);
}
}
extern "thiscall" fn test2(i: i32) {
assert_eq!(i, 2);
}
fn main() {
<S as A>::test1(1);
test2(2);
}
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.24.6 Page: 3034ms Template: 16ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API