File tree Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -91,14 +91,14 @@ impl EarlyLintPass for ModStyle {
9191 // `{ foo => path/to/foo.rs, .. }
9292 let mut file_map = FxHashMap :: default ( ) ;
9393 for file in files. iter ( ) {
94- if let FileName :: Real ( name) = & file. name && let Some ( lp ) = name . local_path ( ) {
95- if file . cnum != LOCAL_CRATE {
96- // [#8887](https://github.com/rust-lang/rust-clippy/issues/8887)
97- // Only check files in the current crate.
98- // Fix false positive that crate dependency in workspace sub directory
99- // is checked unintentionally .
100- continue ;
101- }
94+ if let FileName :: Real ( name) = & file. name
95+ && let Some ( lp ) = name . local_path ( )
96+ && file . cnum == LOCAL_CRATE
97+ {
98+ // [#8887](https://github.com/rust-lang/rust-clippy/issues/8887)
99+ // Only check files in the current crate .
100+ // Fix false positive that crate dependency in workspace sub directory
101+ // is checked unintentionally.
102102 let path = if lp. is_relative ( ) {
103103 lp
104104 } else if let Ok ( relative) = lp. strip_prefix ( trim_to_src) {
You can’t perform that action at this time.
0 commit comments