diff options
| author | lcnr <rust@lcnr.de> | 2025-05-02 16:24:28 +0000 |
|---|---|---|
| committer | lcnr <rust@lcnr.de> | 2025-05-02 18:45:28 +0000 |
| commit | ffa7d1ee5dba9d0a9979d784a5c38e3a05a5ff9e (patch) | |
| tree | 0bb55d6921f0f2b35f6784deb9233d6efb793167 /compiler/rustc_borrowck/src/root_cx.rs | |
| parent | f97b3c6044a67e0b5d0d0891ca3a6c5d982b2285 (diff) | |
| download | rust-ffa7d1ee5dba9d0a9979d784a5c38e3a05a5ff9e.tar.gz rust-ffa7d1ee5dba9d0a9979d784a5c38e3a05a5ff9e.zip | |
borrowck nested items in dead code
Diffstat (limited to 'compiler/rustc_borrowck/src/root_cx.rs')
| -rw-r--r-- | compiler/rustc_borrowck/src/root_cx.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/compiler/rustc_borrowck/src/root_cx.rs b/compiler/rustc_borrowck/src/root_cx.rs index 13daa5c7221..66b526fa02a 100644 --- a/compiler/rustc_borrowck/src/root_cx.rs +++ b/compiler/rustc_borrowck/src/root_cx.rs @@ -62,7 +62,10 @@ impl<'tcx> BorrowCheckRootCtxt<'tcx> { self.tainted_by_errors = Some(guar); } - fn get_or_insert_nested(&mut self, def_id: LocalDefId) -> &PropagatedBorrowCheckResults<'tcx> { + pub(super) fn get_or_insert_nested( + &mut self, + def_id: LocalDefId, + ) -> &PropagatedBorrowCheckResults<'tcx> { debug_assert_eq!( self.tcx.typeck_root_def_id(def_id.to_def_id()), self.root_def_id.to_def_id() |
