From 0463d76a1f7370ea113bbf252281402fabc2a02b Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Sat, 12 Jun 2021 23:39:57 +0300 Subject: internal: cross-crate cov-marks --- crates/hir_ty/Cargo.toml | 2 +- crates/hir_ty/src/diagnostics/decl_check.rs | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'crates/hir_ty') diff --git a/crates/hir_ty/Cargo.toml b/crates/hir_ty/Cargo.toml index 4b714c6d8..a1894e8d8 100644 --- a/crates/hir_ty/Cargo.toml +++ b/crates/hir_ty/Cargo.toml @@ -10,7 +10,7 @@ edition = "2018" doctest = false [dependencies] -cov-mark = { version = "1.1", features = ["thread-local"] } +cov-mark = "2.0.0-pre.1" itertools = "0.10.0" arrayvec = "0.7" smallvec = "1.2.0" diff --git a/crates/hir_ty/src/diagnostics/decl_check.rs b/crates/hir_ty/src/diagnostics/decl_check.rs index ca452e879..f26150b77 100644 --- a/crates/hir_ty/src/diagnostics/decl_check.rs +++ b/crates/hir_ty/src/diagnostics/decl_check.rs @@ -116,6 +116,7 @@ impl<'a> DeclValidator<'a> { fn validate_func(&mut self, func: FunctionId) { let data = self.db.function_data(func); if data.is_in_extern_block() { + cov_mark::hit!(extern_func_incorrect_case_ignored); return; } @@ -572,6 +573,7 @@ impl<'a> DeclValidator<'a> { fn validate_static(&mut self, static_id: StaticId) { let data = self.db.static_data(static_id); if data.is_extern { + cov_mark::hit!(extern_static_incorrect_case_ignored); return; } -- cgit v1.2.3