diff options
| author | Ralf Jung <post@ralfj.de> | 2023-05-10 08:31:30 +0200 |
|---|---|---|
| committer | Ralf Jung <post@ralfj.de> | 2023-05-10 08:31:30 +0200 |
| commit | efa68d02d2ee74f7b70703caef44ff53b92fe910 (patch) | |
| tree | 082e0bc9195c513423a06ef48bb1825f2c2feb97 /compiler/rustc_data_structures/src | |
| parent | 53801d3f085f8b635f0e0f668584c1d618cb1d9d (diff) | |
| parent | 65dfca8488d635552eb246eb8e15df646e987cff (diff) | |
| download | rust-efa68d02d2ee74f7b70703caef44ff53b92fe910.tar.gz rust-efa68d02d2ee74f7b70703caef44ff53b92fe910.zip | |
Merge from rustc
Diffstat (limited to 'compiler/rustc_data_structures/src')
| -rw-r--r-- | compiler/rustc_data_structures/src/owned_slice.rs | 2 | ||||
| -rw-r--r-- | compiler/rustc_data_structures/src/profiling.rs | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/compiler/rustc_data_structures/src/owned_slice.rs b/compiler/rustc_data_structures/src/owned_slice.rs index 048401f66c2..311a42aa42a 100644 --- a/compiler/rustc_data_structures/src/owned_slice.rs +++ b/compiler/rustc_data_structures/src/owned_slice.rs @@ -109,9 +109,11 @@ impl Borrow<[u8]> for OwnedSlice { } // Safety: `OwnedSlice` is conceptually `(&'self.1 [u8], Box<dyn Send + Sync>)`, which is `Send` +#[cfg(parallel_compiler)] unsafe impl Send for OwnedSlice {} // Safety: `OwnedSlice` is conceptually `(&'self.1 [u8], Box<dyn Send + Sync>)`, which is `Sync` +#[cfg(parallel_compiler)] unsafe impl Sync for OwnedSlice {} #[cfg(test)] diff --git a/compiler/rustc_data_structures/src/profiling.rs b/compiler/rustc_data_structures/src/profiling.rs index 572bd4ac21c..5e13e7c8aaf 100644 --- a/compiler/rustc_data_structures/src/profiling.rs +++ b/compiler/rustc_data_structures/src/profiling.rs @@ -101,7 +101,7 @@ use parking_lot::RwLock; use smallvec::SmallVec; bitflags::bitflags! { - struct EventFilter: u32 { + struct EventFilter: u16 { const GENERIC_ACTIVITIES = 1 << 0; const QUERY_PROVIDERS = 1 << 1; const QUERY_CACHE_HITS = 1 << 2; |
