From 999217374f7be95eddee8c109790c6cfa0ce67e5 Mon Sep 17 00:00:00 2001 From: ivan770 Date: Mon, 17 May 2021 11:37:24 +0200 Subject: Added cov mark --- crates/hir_def/src/nameres/collector.rs | 1 + crates/hir_def/src/nameres/tests.rs | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'crates') diff --git a/crates/hir_def/src/nameres/collector.rs b/crates/hir_def/src/nameres/collector.rs index cebc2dc40..19db6cc59 100644 --- a/crates/hir_def/src/nameres/collector.rs +++ b/crates/hir_def/src/nameres/collector.rs @@ -482,6 +482,7 @@ impl DefCollector<'_> { if let Some(ModuleDefId::ModuleId(m)) = res.take_types() { if m == self.def_map.module_id(current_module_id) { + cov_mark::hit!(ignore_macro_use_extern_crate_self); return; } diff --git a/crates/hir_def/src/nameres/tests.rs b/crates/hir_def/src/nameres/tests.rs index 91c37a55d..9f652731d 100644 --- a/crates/hir_def/src/nameres/tests.rs +++ b/crates/hir_def/src/nameres/tests.rs @@ -411,7 +411,8 @@ struct Arc; } #[test] -fn extern_crate_self() { +fn macro_use_extern_crate_self() { + cov_mark::check!(ignore_macro_use_extern_crate_self); check( r#" //- /main.rs crate:main -- cgit v1.2.3