14ea7a777f
This commit adds a new lint - `improper_ctypes_definitions` - which functions identically to `improper_ctypes`, but on `extern "C" fn` definitions (as opposed to `improper_ctypes`'s `extern "C" {}` declarations). Signed-off-by: David Wood <david@davidtw.co>
13 lines
195 B
Rust
13 lines
195 B
Rust
// run-pass
|
|
#![allow(dead_code)]
|
|
// pretty-expanded FIXME #23616
|
|
|
|
struct Empty;
|
|
|
|
// This used to cause an ICE
|
|
#[allow(improper_ctypes_definitions)]
|
|
extern "C" fn ice(_a: Empty) {}
|
|
|
|
fn main() {
|
|
}
|