about summary refs log tree commit diff
path: root/compiler/rustc_borrowck/src
diff options
context:
space:
mode:
authorNicholas Nethercote <n.nethercote@gmail.com>2024-02-02 09:05:53 +1100
committerNicholas Nethercote <n.nethercote@gmail.com>2024-02-02 13:27:57 +1100
commit3a02ebcac27fd730ba89cf1565400d516f296815 (patch)
treed069c0f83fd57e93ae5d0c3d56bb2dc19efb0356 /compiler/rustc_borrowck/src
parentf066be5f2932e791cb766fdf18e9c1fc0d985451 (diff)
downloadrust-3a02ebcac27fd730ba89cf1565400d516f296815.tar.gz
rust-3a02ebcac27fd730ba89cf1565400d516f296815.zip
Remove `BorrowckErrors::set_tainted_by_errors`.
It has no effect. Note that `infcx.set_tainted_by_errors()` is still
called, so taintedness is still being propagated.
Diffstat (limited to 'compiler/rustc_borrowck/src')
-rw-r--r--compiler/rustc_borrowck/src/lib.rs5
1 files changed, 0 insertions, 5 deletions
diff --git a/compiler/rustc_borrowck/src/lib.rs b/compiler/rustc_borrowck/src/lib.rs
index bcd30b3624e..c5a87437003 100644
--- a/compiler/rustc_borrowck/src/lib.rs
+++ b/compiler/rustc_borrowck/src/lib.rs
@@ -178,7 +178,6 @@ fn do_mir_borrowck<'tcx>(
     // Gather the upvars of a closure, if any.
     if let Some(e) = input_body.tainted_by_errors {
         infcx.set_tainted_by_errors(e);
-        errors.set_tainted_by_errors(e);
     }
 
     // Replace all regions with fresh inference variables. This
@@ -2438,10 +2437,6 @@ mod error {
         pub fn buffer_non_error(&mut self, t: DiagnosticBuilder<'_, ()>) {
             self.buffered.push(t.into_diagnostic());
         }
-
-        pub fn set_tainted_by_errors(&mut self, e: ErrorGuaranteed) {
-            self.tainted_by_errors = Some(e);
-        }
     }
 
     impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {