@@ -413,13 +413,13 @@ use std::backtrace::{Backtrace, BacktraceStatus};
413413/// Certain errors (fatal, bug, unimpl) may cause immediate exit,
414414/// others log errors for later reporting.
415415pub struct DiagCtxt {
416- inner : Lock < HandlerInner > ,
416+ inner : Lock < DiagCtxtInner > ,
417417}
418418
419419/// This inner struct exists to keep it all behind a single lock;
420420/// this is done to prevent possible deadlocks in a multi-threaded compiler,
421421/// as well as inconsistent state observation.
422- struct HandlerInner {
422+ struct DiagCtxtInner {
423423 flags : HandlerFlags ,
424424 /// The number of lint errors that have been emitted.
425425 lint_err_count : usize ,
@@ -540,7 +540,7 @@ pub struct HandlerFlags {
540540 pub track_diagnostics : bool ,
541541}
542542
543- impl Drop for HandlerInner {
543+ impl Drop for DiagCtxtInner {
544544 fn drop ( & mut self ) {
545545 self . emit_stashed_diagnostics ( ) ;
546546
@@ -597,7 +597,7 @@ impl DiagCtxt {
597597
598598 pub fn with_emitter ( emitter : Box < DynEmitter > ) -> Self {
599599 Self {
600- inner : Lock :: new ( HandlerInner {
600+ inner : Lock :: new ( DiagCtxtInner {
601601 flags : HandlerFlags { can_emit_warnings : true , ..Default :: default ( ) } ,
602602 lint_err_count : 0 ,
603603 err_count : 0 ,
@@ -1057,7 +1057,7 @@ impl DiagCtxt {
10571057 inner. emit_diagnostic ( diagnostic) . unwrap ( )
10581058 }
10591059
1060- // FIXME(eddyb) note the comment inside `impl Drop for HandlerInner `, that's
1060+ // FIXME(eddyb) note the comment inside `impl Drop for DiagCtxtInner `, that's
10611061 // where the explanation of what "good path" is (also, it should be renamed).
10621062 pub fn good_path_delayed_bug ( & self , msg : impl Into < DiagnosticMessage > ) {
10631063 let mut inner = self . inner . borrow_mut ( ) ;
@@ -1396,12 +1396,12 @@ impl DiagCtxt {
13961396 }
13971397
13981398 /// This methods steals all [`LintExpectationId`]s that are stored inside
1399- /// [`HandlerInner `] and indicate that the linked expectation has been fulfilled.
1399+ /// [`DiagCtxtInner `] and indicate that the linked expectation has been fulfilled.
14001400 #[ must_use]
14011401 pub fn steal_fulfilled_expectation_ids ( & self ) -> FxHashSet < LintExpectationId > {
14021402 assert ! (
14031403 self . inner. borrow( ) . unstable_expect_diagnostics. is_empty( ) ,
1404- "`HandlerInner ::unstable_expect_diagnostics` should be empty at this point" ,
1404+ "`DiagCtxtInner ::unstable_expect_diagnostics` should be empty at this point" ,
14051405 ) ;
14061406 std:: mem:: take ( & mut self . inner . borrow_mut ( ) . fulfilled_expectations )
14071407 }
@@ -1414,10 +1414,10 @@ impl DiagCtxt {
14141414}
14151415
14161416// Note: we prefer implementing operations on `DiagCtxt`, rather than
1417- // `HandlerInner `, whenever possible. This minimizes functions where
1417+ // `DiagCtxtInner `, whenever possible. This minimizes functions where
14181418// `DiagCtxt::foo()` just borrows `inner` and forwards a call to
14191419// `HanderInner::foo`.
1420- impl HandlerInner {
1420+ impl DiagCtxtInner {
14211421 /// Emit all stashed diagnostics.
14221422 fn emit_stashed_diagnostics ( & mut self ) -> Option < ErrorGuaranteed > {
14231423 let has_errors = self . has_errors ( ) ;
0 commit comments