11warning: `clash` redeclared with a different signature
2- --> $DIR/clashing-extern-fn.rs:15:9
2+ --> $DIR/clashing-extern-fn.rs:14:13
33 |
4- LL | fn clash(x: u8);
5- | ---------------- `clash` previously declared here
4+ LL | fn clash(x: u8);
5+ | ---------------- `clash` previously declared here
66...
7- LL | fn clash(x: u64);
8- | ^^^^^^^^^^^^^^^^^ this signature doesn't match the previous declaration
7+ LL | fn clash(x: u64);
8+ | ^^^^^^^^^^^^^^^^^ this signature doesn't match the previous declaration
99 |
1010note: the lint level is defined here
1111 --> $DIR/clashing-extern-fn.rs:4:9
@@ -15,20 +15,8 @@ LL | #![warn(clashing_extern_declarations)]
1515 = note: expected `unsafe extern "C" fn(u8)`
1616 found `unsafe extern "C" fn(u64)`
1717
18- warning: `extern_fn` redeclared with a different signature
19- --> $DIR/clashing-extern-fn.rs:39:9
20- |
21- LL | fn extern_fn(x: u64);
22- | --------------------- `extern_fn` previously declared here
23- ...
24- LL | fn extern_fn(x: u32);
25- | ^^^^^^^^^^^^^^^^^^^^^ this signature doesn't match the previous declaration
26- |
27- = note: expected `unsafe extern "C" fn(u64)`
28- found `unsafe extern "C" fn(u32)`
29-
3018warning: `extern_link_name` redeclared with a different signature
31- --> $DIR/clashing-extern-fn.rs:64 :9
19+ --> $DIR/clashing-extern-fn.rs:52 :9
3220 |
3321LL | / #[link_name = "extern_link_name"]
3422LL | | fn some_new_name(x: i16);
@@ -41,7 +29,7 @@ LL | fn extern_link_name(x: u32);
4129 found `unsafe extern "C" fn(u32)`
4230
4331warning: `some_other_extern_link_name` redeclares `some_other_new_name` with a different signature
44- --> $DIR/clashing-extern-fn.rs:67 :9
32+ --> $DIR/clashing-extern-fn.rs:55 :9
4533 |
4634LL | fn some_other_new_name(x: i16);
4735 | ------------------------------- `some_other_new_name` previously declared here
@@ -55,7 +43,7 @@ LL | | fn some_other_extern_link_name(x: u32);
5543 found `unsafe extern "C" fn(u32)`
5644
5745warning: `other_both_names_different` redeclares `link_name_same` with a different signature
58- --> $DIR/clashing-extern-fn.rs:71 :9
46+ --> $DIR/clashing-extern-fn.rs:59 :9
5947 |
6048LL | / #[link_name = "link_name_same"]
6149LL | | fn both_names_different(x: i16);
@@ -70,7 +58,7 @@ LL | | fn other_both_names_different(x: u32);
7058 found `unsafe extern "C" fn(u32)`
7159
7260warning: `different_mod` redeclared with a different signature
73- --> $DIR/clashing-extern-fn.rs:84 :9
61+ --> $DIR/clashing-extern-fn.rs:72 :9
7462 |
7563LL | fn different_mod(x: u8);
7664 | ------------------------ `different_mod` previously declared here
@@ -82,7 +70,7 @@ LL | fn different_mod(x: u64);
8270 found `unsafe extern "C" fn(u64)`
8371
8472warning: `variadic_decl` redeclared with a different signature
85- --> $DIR/clashing-extern-fn.rs:94 :9
73+ --> $DIR/clashing-extern-fn.rs:82 :9
8674 |
8775LL | fn variadic_decl(x: u8, ...);
8876 | ----------------------------- `variadic_decl` previously declared here
@@ -94,7 +82,7 @@ LL | fn variadic_decl(x: u8);
9482 found `unsafe extern "C" fn(u8)`
9583
9684warning: `weigh_banana` redeclared with a different signature
97- --> $DIR/clashing-extern-fn.rs:154 :13
85+ --> $DIR/clashing-extern-fn.rs:142 :13
9886 |
9987LL | fn weigh_banana(count: *const Banana) -> u64;
10088 | --------------------------------------------- `weigh_banana` previously declared here
@@ -106,7 +94,7 @@ LL | fn weigh_banana(count: *const Banana) -> u64;
10694 found `unsafe extern "C" fn(*const banana::three::Banana) -> u64`
10795
10896warning: `draw_point` redeclared with a different signature
109- --> $DIR/clashing-extern-fn.rs:183 :13
97+ --> $DIR/clashing-extern-fn.rs:171 :13
11098 |
11199LL | fn draw_point(p: Point);
112100 | ------------------------ `draw_point` previously declared here
@@ -117,5 +105,5 @@ LL | fn draw_point(p: Point);
117105 = note: expected `unsafe extern "C" fn(sameish_members::a::Point)`
118106 found `unsafe extern "C" fn(sameish_members::b::Point)`
119107
120- warning: 9 warnings emitted
108+ warning: 8 warnings emitted
121109
0 commit comments