fix: Fix exported_private_dependencies - #338
Conversation
|
To avoid any public-dependency warnings, is it worth adding to |
6715a91 to
1a4eaed
Compare
Sure, I have added that. I think once that stabilizes, this does not become an error. Similarly, enabling warnings here, which was stabilized in 1.97.0, does not throw an error now. For this to make CI fail, we need #347, but that is blocked on the fixes from this PR. So I'd suggest merging this PR first and then consider denying warnings. |
1a4eaed to
c4839c8
Compare
|
I have rebased on main, and I have added |
|
This seems to fix the warnings in the main crate - were you planning to fix the warnings for |
```
$ cargo check -Zpublic-dependency
warning: crate `smallvec` from private dependency 'smallvec' is re-exported
--> src/aml/resource.rs:7:9
|
7 | pub use smallvec;
| ^^^^^^^^
|
= note: `#[warn(exported_private_dependencies)]` on by default
note: dependency `smallvec` declared here
--> Cargo.toml:24:1
|
24 | smallvec = { version = "1.15.2", default-features = false }
| --------
warning: type `RawSpinlock` from private dependency 'spinning_top' in public interface
--> src/aml/mod.rs:106:5
|
106 | pub namespace: Spinlock<Namespace>,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
note: dependency `spinning_top` declared here
--> Cargo.toml:21:1
|
21 | spinning_top = "0.3.0"
| ------------
warning: type `Spin` from private dependency 'spinning_top' in public interface
--> src/aml/mod.rs:106:5
|
106 | pub namespace: Spinlock<Namespace>,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
note: dependency `spinning_top` declared here
--> Cargo.toml:21:1
|
21 | spinning_top = "0.3.0"
| ------------
warning: type `RawSpinlock` from private dependency 'spinning_top' in public interface
--> src/aml/mod.rs:107:5
|
107 | pub object_token: Spinlock<ObjectToken>,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
note: dependency `spinning_top` declared here
--> Cargo.toml:21:1
|
21 | spinning_top = "0.3.0"
| ------------
warning: type `Spin` from private dependency 'spinning_top' in public interface
--> src/aml/mod.rs:107:5
|
107 | pub object_token: Spinlock<ObjectToken>,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
note: dependency `spinning_top` declared here
--> Cargo.toml:21:1
|
21 | spinning_top = "0.3.0"
| ------------
warning: type `SmallVec<[u32; 1]>` from private dependency 'smallvec' in public interface
--> src/aml/resource.rs:343:1
|
343 | pub type Irqs = smallvec::SmallVec<[u32; 1]>;
| ^^^^^^^^^^^^^
note: dependency `smallvec` declared here
--> Cargo.toml:24:1
|
24 | smallvec = { version = "1.15.2", default-features = false }
| --------
warning: type `SmallVec<[u32; 1]>` from private dependency 'smallvec' in public interface
--> src/aml/resource.rs:352:5
|
352 | pub irqs: Irqs,
| ^^^^^^^^^^^^^^
note: dependency `smallvec` declared here
--> Cargo.toml:24:1
|
24 | smallvec = { version = "1.15.2", default-features = false }
| --------
```
Note that the following warnings remain:
```
warning: type `Mutex<RawSpinlock, Namespace>` from private dependency 'lock_api' in public interface
--> src/aml/mod.rs:106:5
|
106 | pub namespace: Spinlock<Namespace>,
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: `#[warn(exported_private_dependencies)]` on by default
warning: type `Mutex<RawSpinlock, ObjectToken>` from private dependency 'lock_api' in public interface
--> src/aml/mod.rs:107:5
|
107 | pub object_token: Spinlock<ObjectToken>,
| ^^^^^^^^^^
```
c4839c8 to
76d1469
Compare
Ah, you are right. I did not notice that one. This should be all now. :) |
|
Perfect, thank you! |
Note that the following warnings remain: