Rust Compile Warning on #link - Not sure what to do

warning: attribute should be applied to an extern block
--> F:\development\Patch\RustyRebar\module\src\native\modulebridge.rs:35:1
|
35 | #[link(name = "ClientDLL", kind="dynlib")]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...
40 | / struct RebarReturnCode {
41 | | type : u32
42 | | }
| |
- not an extern block
|
= note: #[warn(unused_attributes)] on by default
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!

You should not put #[link] statements on structs. That doesn't make sense.

Aha, that's what its telling me, thank you!

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.