Backed out 2 changesets (bug 1939791) for causing build bustages. CLOSED TREE
Backed out changeset 1635a42fc205 (bug 1939791) Backed out changeset f48d5b6b6d8b (bug 1939791)
This commit is contained in:
@@ -31,11 +31,6 @@ impl OpaqueElement {
|
||||
}
|
||||
}
|
||||
|
||||
/// Creates a new OpaqueElement from a type-erased non-null pointer
|
||||
pub fn from_non_null_ptr(ptr: NonNull<()>) -> Self {
|
||||
Self(ptr)
|
||||
}
|
||||
|
||||
/// Returns a const ptr to the contained reference.
|
||||
pub unsafe fn as_const_ptr<T>(&self) -> *const T {
|
||||
self.0.as_ptr() as *const T
|
||||
|
||||
@@ -202,17 +202,14 @@ impl ToResolvedValue for LengthPercentage {
|
||||
|
||||
/// An unpacked `<length-percentage>` that borrows the `calc()` variant.
|
||||
#[derive(Clone, Debug, PartialEq, ToCss)]
|
||||
pub enum Unpacked<'a> {
|
||||
/// A `calc()` value
|
||||
enum Unpacked<'a> {
|
||||
Calc(&'a CalcLengthPercentage),
|
||||
/// A length value
|
||||
Length(Length),
|
||||
/// A percentage value
|
||||
Percentage(Percentage),
|
||||
}
|
||||
|
||||
/// An unpacked `<length-percentage>` that mutably borrows the `calc()` variant.
|
||||
pub enum UnpackedMut<'a> {
|
||||
enum UnpackedMut<'a> {
|
||||
Calc(&'a mut CalcLengthPercentage),
|
||||
Length(Length),
|
||||
Percentage(Percentage),
|
||||
@@ -401,7 +398,7 @@ impl LengthPercentage {
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn unpack<'a>(&'a self) -> Unpacked<'a> {
|
||||
fn unpack<'a>(&'a self) -> Unpacked<'a> {
|
||||
unsafe {
|
||||
match self.tag() {
|
||||
Tag::Calc => Unpacked::Calc(&*self.calc_ptr()),
|
||||
|
||||
Reference in New Issue
Block a user