about summary refs log tree commit diff
diff options
context:
space:
mode:
authorBoxy <rust@boxyuwu.dev>2025-01-18 22:51:27 +0000
committerBoxy <rust@boxyuwu.dev>2025-01-23 06:01:36 +0000
commit744368d83d6fbbe6eefe9bba5283f3ce962391b4 (patch)
treef257c834cea3c4e7a693c6c71772d76845f293a5
parent1f5150b11bdf6708fbdf35bf2c2fd2e5027ca4ae (diff)
downloadrust-744368d83d6fbbe6eefe9bba5283f3ce962391b4.tar.gz
rust-744368d83d6fbbe6eefe9bba5283f3ce962391b4.zip
writeback comment
-rw-r--r--compiler/rustc_hir_typeck/src/writeback.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/rustc_hir_typeck/src/writeback.rs b/compiler/rustc_hir_typeck/src/writeback.rs
index 1d7394fc500..1bf5b19d68d 100644
--- a/compiler/rustc_hir_typeck/src/writeback.rs
+++ b/compiler/rustc_hir_typeck/src/writeback.rs
@@ -371,7 +371,9 @@ impl<'cx, 'tcx> Visitor<'tcx> for WritebackCx<'cx, 'tcx> {
     ) -> Self::Result {
         self.visit_id(inf_id);
 
-        // Ignore cases where the inference is a const.
+        // We don't currently write inference results of const infer vars to
+        // the typeck results as there is not yet any part of the compiler that
+        // needs this information.
         if let Some(ty) = self.fcx.node_ty_opt(inf_id) {
             let ty = self.resolve(ty, &inf_span);
             self.write_ty_to_typeck_results(inf_id, ty);