diff options
-rw-r--r-- | crates/hir_def/src/find_path.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/crates/hir_def/src/find_path.rs b/crates/hir_def/src/find_path.rs index b4362a5c4..109d3552f 100644 --- a/crates/hir_def/src/find_path.rs +++ b/crates/hir_def/src/find_path.rs | |||
@@ -181,6 +181,7 @@ fn find_path_inner( | |||
181 | // dependency in this case. | 181 | // dependency in this case. |
182 | for (module_id, name) in find_local_import_locations(db, item, from) { | 182 | for (module_id, name) in find_local_import_locations(db, item, from) { |
183 | if !visited_modules.insert(module_id) { | 183 | if !visited_modules.insert(module_id) { |
184 | cov_mark::hit!(recursive_imports); | ||
184 | continue; | 185 | continue; |
185 | } | 186 | } |
186 | if let Some(mut path) = find_path_inner( | 187 | if let Some(mut path) = find_path_inner( |
@@ -894,6 +895,7 @@ mod tests { | |||
894 | 895 | ||
895 | #[test] | 896 | #[test] |
896 | fn recursive_pub_mod_reexport() { | 897 | fn recursive_pub_mod_reexport() { |
898 | cov_mark::check!(recursive_imports); | ||
897 | check_found_path( | 899 | check_found_path( |
898 | r#" | 900 | r#" |
899 | fn main() { | 901 | fn main() { |