]> git.lizzy.rs Git - rust.git/commitdiff
Code review fixes
authorKirill Bulatov <mail4score@gmail.com>
Mon, 22 Mar 2021 13:15:53 +0000 (15:15 +0200)
committerKirill Bulatov <mail4score@gmail.com>
Mon, 22 Mar 2021 13:15:53 +0000 (15:15 +0200)
crates/hir_def/src/find_path.rs

index b4362a5c41a46675f83aceb1f363525e9a534998..109d3552f6a2f387ff44dfa4c8fb4bd702219512 100644 (file)
@@ -181,6 +181,7 @@ fn find_path_inner(
         // dependency in this case.
         for (module_id, name) in find_local_import_locations(db, item, from) {
             if !visited_modules.insert(module_id) {
+                cov_mark::hit!(recursive_imports);
                 continue;
             }
             if let Some(mut path) = find_path_inner(
@@ -894,6 +895,7 @@ fn inner() {}
 
     #[test]
     fn recursive_pub_mod_reexport() {
+        cov_mark::check!(recursive_imports);
         check_found_path(
             r#"
 fn main() {