about summary refs log tree commit diff
diff options
context:
space:
mode:
authordianne <diannes.gm@gmail.com>2024-12-19 11:12:31 -0800
committerdianne <diannes.gm@gmail.com>2025-01-06 16:12:11 -0800
commit45b2ae935dbc9feb18e9cb9f87ae04d5978e1669 (patch)
treed987e38e60f7038791eebf8735d60ca3b654340b
parent50222dba2edd2bcf265a8ca4753de0df59bf587d (diff)
downloadrust-45b2ae935dbc9feb18e9cb9f87ae04d5978e1669.tar.gz
rust-45b2ae935dbc9feb18e9cb9f87ae04d5978e1669.zip
remove the unused `ConstraintCategory::ClosureBounds`
-rw-r--r--compiler/rustc_borrowck/src/diagnostics/region_errors.rs1
-rw-r--r--compiler/rustc_middle/src/mir/query.rs5
2 files changed, 0 insertions, 6 deletions
diff --git a/compiler/rustc_borrowck/src/diagnostics/region_errors.rs b/compiler/rustc_borrowck/src/diagnostics/region_errors.rs
index 78809908180..3e90ecbaf5b 100644
--- a/compiler/rustc_borrowck/src/diagnostics/region_errors.rs
+++ b/compiler/rustc_borrowck/src/diagnostics/region_errors.rs
@@ -50,7 +50,6 @@ impl<'tcx> ConstraintDescription for ConstraintCategory<'tcx> {
             ConstraintCategory::Cast { is_implicit_coercion: true, .. } => "coercion ",
             ConstraintCategory::CallArgument(_) => "argument ",
             ConstraintCategory::TypeAnnotation => "type annotation ",
-            ConstraintCategory::ClosureBounds => "closure body ",
             ConstraintCategory::SizedBound => "proving this value is `Sized` ",
             ConstraintCategory::CopyBound => "copying this value ",
             ConstraintCategory::OpaqueType => "opaque type ",
diff --git a/compiler/rustc_middle/src/mir/query.rs b/compiler/rustc_middle/src/mir/query.rs
index c2bb95a91c4..9943914628e 100644
--- a/compiler/rustc_middle/src/mir/query.rs
+++ b/compiler/rustc_middle/src/mir/query.rs
@@ -241,11 +241,6 @@ pub enum ConstraintCategory<'tcx> {
         unsize_to: Option<Ty<'tcx>>,
     },
 
-    /// A constraint that came from checking the body of a closure.
-    ///
-    /// We try to get the category that the closure used when reporting this.
-    ClosureBounds,
-
     /// Contains the function type if available.
     CallArgument(#[derive_where(skip)] Option<Ty<'tcx>>),
     CopyBound,