mirror of
https://github.com/servo/servo.git
synced 2025-08-07 06:25:32 +01:00
style: Introduce ArcSlice, a small wrapper over ThinArc but without an explicit header.
We could make the header PhantomData or something, but then we wouldn't be able to bind to C++, since C++ doesn't have ZSTs. So add a canary instead to add a runtime check of stuff being sane. Differential Revision: https://phabricator.services.mozilla.com/D30133
This commit is contained in:
parent
2ed2151b3d
commit
0d5c4481b8
6 changed files with 98 additions and 3 deletions
|
@ -4,6 +4,7 @@
|
|||
|
||||
//! Value information for devtools.
|
||||
|
||||
use crate::arc_slice::ArcSlice;
|
||||
use servo_arc::Arc;
|
||||
use std::ops::Range;
|
||||
use std::sync::Arc as StdArc;
|
||||
|
@ -116,6 +117,7 @@ impl_generic_specified_value_info!(Option<T>);
|
|||
impl_generic_specified_value_info!(Vec<T>);
|
||||
impl_generic_specified_value_info!(Arc<T>);
|
||||
impl_generic_specified_value_info!(StdArc<T>);
|
||||
impl_generic_specified_value_info!(ArcSlice<T>);
|
||||
impl_generic_specified_value_info!(Range<Idx>);
|
||||
|
||||
impl<T1, T2> SpecifiedValueInfo for (T1, T2)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue