rust/tests/ui/lint/issue-1866.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

30 lines
647 B
Rust
Raw Normal View History

//@ build-pass
#![allow(dead_code)]
#![allow(non_camel_case_types)]
#![warn(clashing_extern_declarations)]
//@ pretty-expanded FIXME #23616
mod a {
pub type rust_task = usize;
pub mod rustrt {
2013-06-22 18:43:15 +00:00
use super::rust_task;
2020-09-01 21:12:52 +00:00
extern "C" {
2014-06-25 19:47:34 +00:00
pub fn rust_task_is_unwinding(rt: *const rust_task) -> bool;
}
}
}
mod b {
pub type rust_task = bool;
pub mod rustrt {
2013-06-22 18:43:15 +00:00
use super::rust_task;
2020-09-01 21:12:52 +00:00
extern "C" {
2014-06-25 19:47:34 +00:00
pub fn rust_task_is_unwinding(rt: *const rust_task) -> bool;
2020-09-01 21:12:52 +00:00
//~^ WARN `rust_task_is_unwinding` redeclared with a different signature
}
}
}
2020-09-01 21:12:52 +00:00
pub fn main() {}