mirror of
https://github.com/servo/servo.git
synced 2025-08-06 06:00:15 +01:00
use HeapSizeOf plugin in gfx
This commit is contained in:
parent
f4bc92526a
commit
c1daf889af
5 changed files with 22 additions and 21 deletions
|
@ -165,7 +165,7 @@ macro_rules! known_heap_size(
|
|||
($size:expr, $($ty:ident),+) => (
|
||||
$(
|
||||
impl $crate::mem::HeapSizeOf for $ty {
|
||||
#[inline]
|
||||
#[inline(always)]
|
||||
fn heap_size_of_children(&self) -> usize {
|
||||
$size
|
||||
}
|
||||
|
@ -174,7 +174,7 @@ macro_rules! known_heap_size(
|
|||
);
|
||||
($size: expr, $ty:ident<$($gen:ident),+>) => (
|
||||
impl<$($gen),+> $crate::mem::HeapSizeOf for $ty<$($gen),+> {
|
||||
#[inline]
|
||||
#[inline(always)]
|
||||
fn heap_size_of_children(&self) -> usize {
|
||||
$size
|
||||
}
|
||||
|
@ -185,4 +185,4 @@ macro_rules! known_heap_size(
|
|||
|
||||
known_heap_size!(0, u8, u16, u32, u64, usize);
|
||||
known_heap_size!(0, i8, i16, i32, i64, isize);
|
||||
known_heap_size!(0, bool);
|
||||
known_heap_size!(0, bool);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue