mirror of
https://github.com/servo/servo.git
synced 2025-08-03 20:50:07 +01:00
remove various things now that Rust 1.17 is required
std::ptr::eq and Arc::ptr_eq are now usuable, and we can replace a panic!() with abort().
This commit is contained in:
parent
567f5e8985
commit
096cee8ebc
6 changed files with 7 additions and 26 deletions
|
@ -10,6 +10,8 @@ use atomic_refcell::{AtomicRefCell, AtomicRef, AtomicRefMut};
|
|||
use parking_lot::RwLock;
|
||||
use std::cell::UnsafeCell;
|
||||
use std::fmt;
|
||||
#[cfg(feature = "gecko")]
|
||||
use std::ptr;
|
||||
use stylearc::Arc;
|
||||
|
||||
/// A shared read/write lock that can protect multiple objects.
|
||||
|
@ -154,7 +156,7 @@ impl<T> Locked<T> {
|
|||
|
||||
#[cfg(feature = "gecko")]
|
||||
fn same_lock_as(&self, derefed_guard: &SomethingZeroSizedButTyped) -> bool {
|
||||
::ptr_eq(self.shared_lock.cell.as_ptr(), derefed_guard)
|
||||
ptr::eq(self.shared_lock.cell.as_ptr(), derefed_guard)
|
||||
}
|
||||
|
||||
/// Access the data for reading.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue