@@ -364,9 +364,6 @@ pub fn run_core(options: RustdocOptions) -> (clean::Crate, RenderInfo, RenderOpt
364
364
..Options :: default ( )
365
365
} ;
366
366
367
- lazy_static ! {
368
- static ref EMPTY_MAP : FxHashSet <LocalDefId > = FxHashSet :: default ( ) ;
369
- }
370
367
let config = interface:: Config {
371
368
opts : sessopts,
372
369
crate_cfg : interface:: parse_cfgspecs ( cfgs) ,
@@ -381,12 +378,15 @@ pub fn run_core(options: RustdocOptions) -> (clean::Crate, RenderInfo, RenderOpt
381
378
lint_caps,
382
379
register_lints : None ,
383
380
override_queries : Some ( |_sess, local_providers, external_providers| {
381
+ lazy_static ! {
382
+ static ref EMPTY_SET : FxHashSet <LocalDefId > = FxHashSet :: default ( ) ;
383
+ }
384
384
// Most lints will require typechecking, so just don't run them.
385
385
local_providers. lint_mod = |_, _| { } ;
386
386
external_providers. lint_mod = |_, _| { } ;
387
387
local_providers. typeck_item_bodies = |_, _| { } ;
388
388
// hack so that `used_trait_imports` won't try to call typeck_tables_of
389
- local_providers. used_trait_imports = |_, _| & EMPTY_MAP ;
389
+ local_providers. used_trait_imports = |_, _| & EMPTY_SET ;
390
390
// In case typeck does end up being called, don't ICE in case there were name resolution errors
391
391
local_providers. typeck_tables_of = move |tcx, def_id| {
392
392
// Closures' tables come from their outermost function,
0 commit comments