mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Change #[privatize] into #[derive(DenyPublicFields)]
This commit is contained in:
parent
19c645ff68
commit
8bcf36b9a5
16 changed files with 69 additions and 65 deletions
|
@ -28,8 +28,7 @@ use std::rc::Rc;
|
|||
#[derive(JSTraceable, PartialEq, Eq, Copy, Clone, HeapSizeOf, Hash, PartialOrd, Ord, Debug)]
|
||||
pub struct OneshotTimerHandle(i32);
|
||||
|
||||
#[derive(JSTraceable, HeapSizeOf)]
|
||||
#[privatize]
|
||||
#[derive(DenyPublicFields, HeapSizeOf, JSTraceable)]
|
||||
pub struct OneshotTimers {
|
||||
js_timers: JsTimers,
|
||||
#[ignore_heap_size_of = "Defined in std"]
|
||||
|
@ -53,8 +52,7 @@ pub struct OneshotTimers {
|
|||
expected_event_id: Cell<TimerEventId>,
|
||||
}
|
||||
|
||||
#[derive(JSTraceable, HeapSizeOf)]
|
||||
#[privatize]
|
||||
#[derive(DenyPublicFields, HeapSizeOf, JSTraceable)]
|
||||
struct OneshotTimer {
|
||||
handle: OneshotTimerHandle,
|
||||
source: TimerSource,
|
||||
|
@ -302,8 +300,7 @@ impl OneshotTimers {
|
|||
#[derive(JSTraceable, PartialEq, Eq, Copy, Clone, HeapSizeOf, Hash, PartialOrd, Ord)]
|
||||
pub struct JsTimerHandle(i32);
|
||||
|
||||
#[derive(JSTraceable, HeapSizeOf)]
|
||||
#[privatize]
|
||||
#[derive(DenyPublicFields, HeapSizeOf, JSTraceable)]
|
||||
pub struct JsTimers {
|
||||
next_timer_handle: Cell<JsTimerHandle>,
|
||||
active_timers: DOMRefCell<HashMap<JsTimerHandle, JsTimerEntry>>,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue