Skip to content

Commit

Permalink
servo: Merge #16473 - Upgrade to rustc 1.18.0-nightly (5f13a3b54 2017…
Browse files Browse the repository at this point in the history
…-04-15) (from servo:rustup); r=emilio

This version enables [struct field reordering][1] which brings the size of the types for specified values of some CSS properties under the threshold such that they shouldn’t be boxed anymore, making unit tests fail.

Simply unboxing them moves the test failure to Stylo’s unit tests, since the stable compiler used in that case does not do field re-ordering. Therefore, we manually reorder a couple fields to effectively bring this optimization to older compilers for a few specific types.

[1]: rust-lang/rust#40377

Source-Repo: https://github.com/servo/servo
Source-Revision: c453e2ef89b32798dabbb23b22cfd5a72dddf6a5

UltraBlame original commit: 55519369af2b2a65f2a5c2275522a8b1dc014953
  • Loading branch information
marco-c committed Oct 1, 2019
1 parent 9f759ee commit ff0f91b
Show file tree
Hide file tree
Showing 11 changed files with 7 additions and 255 deletions.
24 changes: 0 additions & 24 deletions servo/components/script/dom/element.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5138,11 +5138,6 @@ PropertyDeclaration
:
BorderTopWidth
(
Box
:
:
new
(
width_value
.
clone
Expand All @@ -5151,7 +5146,6 @@ clone
)
)
)
)
;
hints
.
Expand All @@ -5165,11 +5159,6 @@ PropertyDeclaration
:
BorderLeftWidth
(
Box
:
:
new
(
width_value
.
clone
Expand All @@ -5178,7 +5167,6 @@ clone
)
)
)
)
;
hints
.
Expand All @@ -5192,11 +5180,6 @@ PropertyDeclaration
:
BorderBottomWidth
(
Box
:
:
new
(
width_value
.
clone
Expand All @@ -5205,7 +5188,6 @@ clone
)
)
)
)
;
hints
.
Expand All @@ -5219,16 +5201,10 @@ PropertyDeclaration
:
BorderRightWidth
(
Box
:
:
new
(
width_value
)
)
)
)
;
}
}
Expand Down
5 changes: 0 additions & 5 deletions servo/components/style/properties/longhand/border.mako.rs
Original file line number Diff line number Diff line change
Expand Up @@ -401,11 +401,6 @@ side
-
width
"
boxed
=
"
True
"
animation_type
=
"
Expand Down
3 changes: 0 additions & 3 deletions servo/components/style/properties/longhand/box.mako.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15520,9 +15520,6 @@ extra_prefixes
moz
webkit
"
boxed
=
True
creates_stacking_context
=
True
Expand Down
11 changes: 0 additions & 11 deletions servo/components/style/properties/longhand/column.mako.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,6 @@ extra_prefixes
"
moz
"
boxed
=
True
animation_type
=
"
Expand Down Expand Up @@ -263,9 +260,6 @@ moz
experimental
=
True
boxed
=
True
animation_type
=
"
Expand Down Expand Up @@ -397,11 +391,6 @@ products
"
gecko
"
boxed
=
"
True
"
animation_type
=
"
Expand Down
13 changes: 0 additions & 13 deletions servo/components/style/properties/longhand/inherited_text.mako.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3265,11 +3265,6 @@ letter
-
spacing
"
boxed
=
"
True
"
animation_type
=
"
Expand Down Expand Up @@ -9089,9 +9084,6 @@ products
"
gecko
"
boxed
=
True
animation_type
=
"
Expand Down Expand Up @@ -9313,11 +9305,6 @@ stroke
-
width
"
boxed
=
"
True
"
animation_type
=
"
Expand Down
2 changes: 1 addition & 1 deletion servo/components/style/values/computed/length.rs
Original file line number Diff line number Diff line change
Expand Up @@ -335,9 +335,9 @@ Length
:
Calc
(
range
ref
calc
range
)
=
>
Expand Down
10 changes: 5 additions & 5 deletions servo/components/style/values/specified/length.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2784,11 +2784,11 @@ NoCalcLength
)
Calc
(
AllowedLengthType
Box
<
CalcLengthOrPercentage
>
AllowedLengthType
)
}
impl
Expand Down Expand Up @@ -2862,9 +2862,9 @@ Length
:
Calc
(
_
ref
calc
_
)
=
>
Expand Down Expand Up @@ -2934,9 +2934,9 @@ Length
:
Calc
(
_
ref
calc
_
)
=
>
Expand Down Expand Up @@ -5310,14 +5310,14 @@ Length
:
Calc
(
num_context
Box
:
:
new
(
calc
)
num_context
)
}
)
Expand Down Expand Up @@ -6950,8 +6950,8 @@ Length
:
Calc
(
l
_
l
)
=
>
Expand Down
24 changes: 0 additions & 24 deletions servo/ports/geckolib/glue.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10533,11 +10533,6 @@ into
BorderTopWidth
=
>
Box
:
:
new
(
BorderWidth
:
:
Expand All @@ -10549,15 +10544,9 @@ into
(
)
)
)
BorderRightWidth
=
>
Box
:
:
new
(
BorderWidth
:
:
Expand All @@ -10569,15 +10558,9 @@ into
(
)
)
)
BorderBottomWidth
=
>
Box
:
:
new
(
BorderWidth
:
:
Expand All @@ -10589,15 +10572,9 @@ into
(
)
)
)
BorderLeftWidth
=
>
Box
:
:
new
(
BorderWidth
:
:
Expand All @@ -10609,7 +10586,6 @@ into
(
)
)
)
MarginTop
=
>
Expand Down
2 changes: 1 addition & 1 deletion servo/rust-commit-hash
Original file line number Diff line number Diff line change
@@ -1 +1 @@
474f7a91eec8cba83b7eb7a578a7adb70614f877
5f13a3b540ab6024665322d716e487c800645f24
Loading

0 comments on commit ff0f91b

Please sign in to comment.