about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEsteban Küber <esteban@kuber.com.ar>2020-09-23 23:20:49 -0700
committerEsteban Küber <esteban@kuber.com.ar>2020-10-09 14:44:24 -0700
commitfdbe4ce5c14286f2b3081ed17718ed5c26d6780a (patch)
tree96c89ba6da0800f050fc04dd4eff38046370cbcf
parent5e23cc49601776e97aed012fdbe268206df11c3e (diff)
downloadrust-fdbe4ce5c14286f2b3081ed17718ed5c26d6780a.tar.gz
rust-fdbe4ce5c14286f2b3081ed17718ed5c26d6780a.zip
Add docstring
-rw-r--r--compiler/rustc_resolve/src/late.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/compiler/rustc_resolve/src/late.rs b/compiler/rustc_resolve/src/late.rs
index a1538818df3..219517b4ab2 100644
--- a/compiler/rustc_resolve/src/late.rs
+++ b/compiler/rustc_resolve/src/late.rs
@@ -385,6 +385,8 @@ struct DiagnosticMetadata<'ast> {
     /// Used to detect possible `if let` written without `let` and to provide structured suggestion.
     in_if_condition: Option<&'ast Expr>,
 
+    /// If we are currently in a trait object definition. Used to point at the bounds when
+    /// encountering a struct or enum.
     current_trait_object: Option<&'ast [ast::GenericBound]>,
 
     /// Given `where <T as Bar>::Baz: String`, suggest `where T: Bar<Baz = String>`.