EMPTY_MAP -> EMPTY_SET
This commit is contained in:
parent
b2ff0e703e
commit
ac9157b482
1 changed files with 4 additions and 4 deletions
|
|
@ -364,9 +364,6 @@ pub fn run_core(options: RustdocOptions) -> (clean::Crate, RenderInfo, RenderOpt
|
|||
..Options::default()
|
||||
};
|
||||
|
||||
lazy_static! {
|
||||
static ref EMPTY_MAP: FxHashSet<LocalDefId> = FxHashSet::default();
|
||||
}
|
||||
let config = interface::Config {
|
||||
opts: sessopts,
|
||||
crate_cfg: interface::parse_cfgspecs(cfgs),
|
||||
|
|
@ -381,12 +378,15 @@ pub fn run_core(options: RustdocOptions) -> (clean::Crate, RenderInfo, RenderOpt
|
|||
lint_caps,
|
||||
register_lints: None,
|
||||
override_queries: Some(|_sess, local_providers, external_providers| {
|
||||
lazy_static! {
|
||||
static ref EMPTY_SET: FxHashSet<LocalDefId> = FxHashSet::default();
|
||||
}
|
||||
// Most lints will require typechecking, so just don't run them.
|
||||
local_providers.lint_mod = |_, _| {};
|
||||
external_providers.lint_mod = |_, _| {};
|
||||
local_providers.typeck_item_bodies = |_, _| {};
|
||||
// hack so that `used_trait_imports` won't try to call typeck_tables_of
|
||||
local_providers.used_trait_imports = |_, _| &EMPTY_MAP;
|
||||
local_providers.used_trait_imports = |_, _| &EMPTY_SET;
|
||||
// In case typeck does end up being called, don't ICE in case there were name resolution errors
|
||||
local_providers.typeck_tables_of = move |tcx, def_id| {
|
||||
// Closures' tables come from their outermost function,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue