Auto merge of #19829 - servo:rustup, r=nox

Update Rust and use the newly-stable std::ptr::NonNull

<!-- Reviewable:start -->
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/19829)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2018-01-22 11:11:44 -06:00 committed by GitHub
commit c1ed4bb2d5
44 changed files with 137 additions and 177 deletions

View file

@ -548,7 +548,7 @@ impl SizeConstraint {
max_size = max_size.map(|x| max(x, min_size));
if let Some(border) = border {
min_size = max((min_size - border), Au(0));
min_size = max(min_size - border, Au(0));
max_size = max_size.map(|x| max(x - border, Au(0)));
}

View file

@ -868,7 +868,7 @@ pub fn process_node_overflow_request<N: LayoutNode>(requested_node: N) -> NodeOv
let style = &*layout_node.as_element().unwrap().resolved_style();
let style_box = style.get_box();
NodeOverflowResponse(Some((Point2D::new(style_box.overflow_x, style_box.overflow_y))))
NodeOverflowResponse(Some(Point2D::new(style_box.overflow_x, style_box.overflow_y)))
}
pub fn process_margin_style_query<N: LayoutNode>(requested_node: N)

View file

@ -67,7 +67,7 @@ pub trait GetRawData {
impl<T: GetLayoutData> GetRawData for T {
fn get_raw_data(&self) -> Option<&StyleAndLayoutData> {
self.get_style_and_layout_data().map(|opaque| {
let container = opaque.ptr.get() as *mut StyleAndLayoutData;
let container = opaque.ptr.as_ptr() as *mut StyleAndLayoutData;
unsafe { &*container }
})
}