@@ -375,7 +375,6 @@ pub fn run_core(options: RustdocOptions) -> (clean::Crate, RenderInfo, RenderOpt
375375 override_queries : Some ( |_sess, local_providers, external_providers| {
376376 local_providers. lint_mod = |_, _| { } ;
377377 external_providers. lint_mod = |_, _| { } ;
378- //let old_typeck = local_providers.typeck_tables_of;
379378 local_providers. typeck_tables_of = move |tcx, def_id| {
380379 // Closures' tables come from their outermost function,
381380 // as they are part of the same "inference environment".
@@ -389,8 +388,7 @@ pub fn run_core(options: RustdocOptions) -> (clean::Crate, RenderInfo, RenderOpt
389388 let body = hir. body ( hir. body_owned_by ( hir. as_local_hir_id ( def_id) ) ) ;
390389 debug ! ( "visiting body for {:?}" , def_id) ;
391390 EmitIgnoredResolutionErrors :: new ( & tcx. sess , hir) . visit_body ( body) ;
392- rustc_typeck:: check:: typeck_tables_of ( tcx, def_id)
393- //DEFAULT_TYPECK.with(|typeck| typeck(tcx, def_id))
391+ DEFAULT_TYPECK . with ( |typeck| typeck ( tcx, def_id) )
394392 } ;
395393 } ) ,
396394 registry : rustc_driver:: diagnostics_registry ( ) ,
@@ -596,13 +594,11 @@ use rustc_hir::{
596594} ;
597595use rustc_middle:: hir:: map:: Map ;
598596
599- /*
600597thread_local ! ( static DEFAULT_TYPECK : for <' tcx> fn ( rustc_middle:: ty:: TyCtxt <' tcx>, rustc_span:: def_id:: LocalDefId ) -> & ' tcx rustc_middle:: ty:: TypeckTables <' tcx> = {
601598 let mut providers = rustc_middle:: ty:: query:: Providers :: default ( ) ;
602599 rustc_typeck:: provide( & mut providers) ;
603600 providers. typeck_tables_of
604601} ) ;
605- */
606602
607603/// Due to https://github.com/rust-lang/rust/pull/73566,
608604/// the name resolution pass may find errors that are never emitted.
0 commit comments