about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-03-24 16:09:51 +0000
committerbors <bors@rust-lang.org>2024-03-24 16:09:51 +0000
commitd36bdd19f2940876e84d4e68f2ec3832507b3a33 (patch)
tree023271c928991b253dc6d143dd9cbc039bb6cae4 /compiler/rustc_codegen_llvm/src
parent6e6c72174207174077905315d13cbf7ed9043475 (diff)
parentcdf86bf4430a6b068eb2acec2c5bbf4f87ee1118 (diff)
downloadrust-d36bdd19f2940876e84d4e68f2ec3832507b3a33.tar.gz
rust-d36bdd19f2940876e84d4e68f2ec3832507b3a33.zip
Auto merge of #123004 - matthiaskrgr:rollup-s3v4p50, r=matthiaskrgr
Rollup of 10 pull requests

Successful merges:

 - #122737 (conditionally ignore fatal diagnostic in the SilentEmitter)
 - #122757 (Fixed the `private-dependency` bug)
 - #122886 (add test for #90192)
 - #122937 (Unbox and unwrap the contents of `StatementKind::Coverage`)
 - #122949 (Add a regression test for #117310)
 - #122962 (Track run-make-support lib in common inputs stamp)
 - #122977 (Rename `Arguments::as_const_str` to `as_statically_known_str`)
 - #122983 (Fix build failure on ARM/AArch64/PowerPC/RISC-V FreeBSD/NetBSD)
 - #122984 (panic-in-panic-hook: formatting a message that's just a string is risk-free)
 - #122992 (std::thread: refine available_parallelism for solaris/illumos.)

r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_codegen_llvm/src')
-rw-r--r--compiler/rustc_codegen_llvm/src/coverageinfo/mod.rs4
1 files changed, 1 insertions, 3 deletions
diff --git a/compiler/rustc_codegen_llvm/src/coverageinfo/mod.rs b/compiler/rustc_codegen_llvm/src/coverageinfo/mod.rs
index 54f4bc06340..85277db6d53 100644
--- a/compiler/rustc_codegen_llvm/src/coverageinfo/mod.rs
+++ b/compiler/rustc_codegen_llvm/src/coverageinfo/mod.rs
@@ -14,7 +14,6 @@ use rustc_data_structures::fx::{FxHashMap, FxIndexMap};
 use rustc_llvm::RustString;
 use rustc_middle::bug;
 use rustc_middle::mir::coverage::CoverageKind;
-use rustc_middle::mir::Coverage;
 use rustc_middle::ty::layout::HasTyCtxt;
 use rustc_middle::ty::Instance;
 
@@ -75,7 +74,7 @@ impl<'ll, 'tcx> CodegenCx<'ll, 'tcx> {
 
 impl<'tcx> CoverageInfoBuilderMethods<'tcx> for Builder<'_, '_, 'tcx> {
     #[instrument(level = "debug", skip(self))]
-    fn add_coverage(&mut self, instance: Instance<'tcx>, coverage: &Coverage) {
+    fn add_coverage(&mut self, instance: Instance<'tcx>, kind: &CoverageKind) {
         // Our caller should have already taken care of inlining subtleties,
         // so we can assume that counter/expression IDs in this coverage
         // statement are meaningful for the given instance.
@@ -98,7 +97,6 @@ impl<'tcx> CoverageInfoBuilderMethods<'tcx> for Builder<'_, '_, 'tcx> {
             .entry(instance)
             .or_insert_with(|| FunctionCoverageCollector::new(instance, function_coverage_info));
 
-        let Coverage { kind } = coverage;
         match *kind {
             CoverageKind::SpanMarker | CoverageKind::BlockMarker { .. } => unreachable!(
                 "marker statement {kind:?} should have been removed by CleanupPostBorrowck"