about summary refs log tree commit diff
path: root/compiler/rustc_middle/src
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/rustc_middle/src')
-rw-r--r--compiler/rustc_middle/src/mir/query.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/compiler/rustc_middle/src/mir/query.rs b/compiler/rustc_middle/src/mir/query.rs
index 429be9bc725..c2bb95a91c4 100644
--- a/compiler/rustc_middle/src/mir/query.rs
+++ b/compiler/rustc_middle/src/mir/query.rs
@@ -250,7 +250,12 @@ pub enum ConstraintCategory<'tcx> {
     CallArgument(#[derive_where(skip)] Option<Ty<'tcx>>),
     CopyBound,
     SizedBound,
-    Assignment,
+    Assignment {
+        /// Whether this assignment is likely to be interesting to refer to in diagnostics.
+        /// Currently, this is true when it's assigning to a projection, when it's assigning from
+        /// the return value of a call, and when it has a user-provided type annotation.
+        has_interesting_ty: bool,
+    },
     /// A constraint that came from a usage of a variable (e.g. in an ADT expression
     /// like `Foo { field: my_val }`)
     Usage,