2021-04-15 16:19:23 -05:00
|
|
|
#[no_mangle]
|
|
|
|
fn foo() {}
|
2022-07-11 06:44:55 -05:00
|
|
|
//~^ HELP: it's first defined here, in crate `exported_symbol_clashing`
|
2021-04-15 16:19:23 -05:00
|
|
|
|
|
|
|
#[export_name = "foo"]
|
|
|
|
fn bar() {}
|
2022-07-11 06:44:55 -05:00
|
|
|
//~^ HELP: then it's defined here again, in crate `exported_symbol_clashing`
|
2021-04-15 16:19:23 -05:00
|
|
|
|
|
|
|
fn main() {
|
|
|
|
extern "Rust" {
|
|
|
|
fn foo();
|
|
|
|
}
|
|
|
|
unsafe { foo() }
|
2022-07-11 06:44:55 -05:00
|
|
|
//~^ ERROR: multiple definitions of symbol `foo`
|
2021-04-15 16:19:23 -05:00
|
|
|
}
|