mv compiler to compiler/
This commit is contained in:
parent
db534b3ac2
commit
9e5f7d5631
1686 changed files with 941 additions and 1051 deletions
14
compiler/rustc_data_structures/src/fx.rs
Normal file
14
compiler/rustc_data_structures/src/fx.rs
Normal file
|
@ -0,0 +1,14 @@
|
|||
use std::hash::BuildHasherDefault;
|
||||
|
||||
pub use rustc_hash::{FxHashMap, FxHashSet, FxHasher};
|
||||
|
||||
pub type FxIndexMap<K, V> = indexmap::IndexMap<K, V, BuildHasherDefault<FxHasher>>;
|
||||
pub type FxIndexSet<V> = indexmap::IndexSet<V, BuildHasherDefault<FxHasher>>;
|
||||
|
||||
#[macro_export]
|
||||
macro_rules! define_id_collections {
|
||||
($map_name:ident, $set_name:ident, $key:ty) => {
|
||||
pub type $map_name<T> = $crate::fx::FxHashMap<$key, T>;
|
||||
pub type $set_name = $crate::fx::FxHashSet<$key>;
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue