diff --git a/crates/oxc_linter/src/service/module_cache.rs b/crates/oxc_linter/src/service/module_cache.rs index b46b2ff30552f..3bb4196c5f75e 100644 --- a/crates/oxc_linter/src/service/module_cache.rs +++ b/crates/oxc_linter/src/service/module_cache.rs @@ -5,9 +5,11 @@ use std::{ use dashmap::{mapref::one::Ref, DashMap}; use oxc_semantic::ModuleRecord; -use rustc_hash::FxHashMap; +use rustc_hash::{FxBuildHasher, FxHashMap}; use std::num::NonZeroUsize; +type FxDashMap = DashMap; + /// `CacheState` and `CacheStateEntry` are used to fix the problem where /// there is a brief moment when a concurrent fetch can miss the cache. /// @@ -26,7 +28,7 @@ enum CacheStateEntry { } /// Keyed by canonicalized path -type ModuleMap = DashMap, ModuleState>; +type ModuleMap = FxDashMap, ModuleState>; #[derive(Clone)] pub(super) enum ModuleState {