diff options
author | Aleksey Kladov <[email protected]> | 2020-11-02 12:13:32 +0000 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2020-11-02 13:07:08 +0000 |
commit | b6101184537b1165cfdd5fc473e04ad4c5b7bffa (patch) | |
tree | bcc2efd8a2696840a4724ad88758e973ecb77157 /crates/hir_def/src/nameres/collector.rs | |
parent | e7f90866bcf4b04a11e958eda0ac53f7ff0a607b (diff) |
Deny unreachable-pub
It's very useful when `pub` is equivalent to "this is crate's public
API", let's enforce this!
Ideally, we should enforce it for local `cargo test`, and only during
CI, but that needs https://github.com/rust-lang/cargo/issues/5034.
Diffstat (limited to 'crates/hir_def/src/nameres/collector.rs')
-rw-r--r-- | crates/hir_def/src/nameres/collector.rs | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/crates/hir_def/src/nameres/collector.rs b/crates/hir_def/src/nameres/collector.rs index 1ff45d244..59b6644c3 100644 --- a/crates/hir_def/src/nameres/collector.rs +++ b/crates/hir_def/src/nameres/collector.rs | |||
@@ -122,13 +122,13 @@ enum ImportSource { | |||
122 | 122 | ||
123 | #[derive(Clone, Debug, Eq, PartialEq)] | 123 | #[derive(Clone, Debug, Eq, PartialEq)] |
124 | struct Import { | 124 | struct Import { |
125 | pub path: ModPath, | 125 | path: ModPath, |
126 | pub alias: Option<ImportAlias>, | 126 | alias: Option<ImportAlias>, |
127 | pub visibility: RawVisibility, | 127 | visibility: RawVisibility, |
128 | pub is_glob: bool, | 128 | is_glob: bool, |
129 | pub is_prelude: bool, | 129 | is_prelude: bool, |
130 | pub is_extern_crate: bool, | 130 | is_extern_crate: bool, |
131 | pub is_macro_use: bool, | 131 | is_macro_use: bool, |
132 | source: ImportSource, | 132 | source: ImportSource, |
133 | } | 133 | } |
134 | 134 | ||