]> git.proxmox.com Git - rustc.git/blob - tests/ui/rfc-2627-raw-dylib/import-name-type-unsupported-link-kind.rs
New upstream version 1.68.2+dfsg1
[rustc.git] / tests / ui / rfc-2627-raw-dylib / import-name-type-unsupported-link-kind.rs
1 // only-windows
2 // only-x86
3 #![feature(raw_dylib)]
4
5 #[link(name = "foo", import_name_type = "decorated")]
6 //~^ ERROR import name type can only be used with link kind `raw-dylib`
7 extern "C" { }
8
9 #[link(name = "bar", kind = "static", import_name_type = "decorated")]
10 //~^ ERROR import name type can only be used with link kind `raw-dylib`
11 extern "C" { }
12
13 // Specifying `import_name_type` before `kind` shouldn't raise an error.
14 #[link(name = "bar", import_name_type = "decorated", kind = "raw-dylib")]
15 extern "C" { }
16
17 fn main() {}