Closed Bug 1460439 Opened 6 years ago Closed 6 years ago

Convert NS_STYLE_BORDER_STYLE_* to enum class

Categories

(Core :: CSS Parsing and Computation, enhancement, P3)

enhancement

Tracking

()

RESOLVED FIXED
mozilla65
Tracking Status
firefox65 --- fixed

People

(Reporter: KrisWright, Assigned: KrisWright, Mentored)

References

Details

Attachments

(1 file, 10 obsolete files)

76.42 KB, patch
Details | Diff | Splinter Review
+++ This bug was initially created as a clone of Bug #1459367 +++

We would like to convert the |NS_STYLE_BORDER_STYLE_*| #defines [1] to an enum class.

Other conversions in nsStyleConsts.h [2, bug 1313565] can be used as an example. The basic steps are:
  #1 - declare an `enum class StyleBorderStyle`
  #2 - convert the #defines to enum values with UpperCamel naming, ie NS_STYLE_BORDER_STYLE_NONE => None
  #3 - replace member variables and params that store NS_STYLE_BORDER_STYLE_* values to use the new type, ie `uint8_t mBorderStyles` => `StyleBorderStyle mBorderStyles` [3]
  #4 - replace uses of the #defines with the new enum naming, ie NS_STYLE_BORDER_STYLE => StyleBorderStyle::None
  #5 - Update mako file with new enum values ie 'gecko_constant_prefix="NS_STYLE_BORDER_STYLE"' => 'gecko_enum_prefix="StyleBorderStyle"' [4]
  #6 - Update rusty-enums servo bindings with mozilla::StyleBorderStyle and add it to the whitelist values

[1] https://searchfox.org/mozilla-central/rev/eb6c5214a63e20a3fff455e92c876287a8d2e188/layout/style/nsStyleConsts.h#312-322
[2] https://searchfox.org/mozilla-central/rev/53afcfdbabed96883126d0ebbcac499b358e32f2/layout/style/nsStyleConsts.h#226-232
[3] https://searchfox.org/mozilla-central/rev/eb6c5214a63e20a3fff455e92c876287a8d2e188/layout/painting/nsCSSRenderingBorders.h#144
[4] https://searchfox.org/mozilla-central/rev/eb6c5214a63e20a3fff455e92c876287a8d2e188/servo/components/style/properties/longhand/column.mako.rs#70
Here is what I have so far. Converted the enum class. Will not build.
Assignee: nobody → kwright
Status: NEW → ASSIGNED
Depends on: 1460682
Comment on attachment 8974770 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

Review of attachment 8974770 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good so far, there are a few missing pieces that I've noted in the review.

::: dom/html/HTMLHRElement.cpp
@@ -139,4 @@
>  
>      if (!aData->PropertyIsSet(eCSSProperty_border_top_style))
>        aData->SetKeywordValue(eCSSProperty_border_top_style,
> -                             NS_STYLE_BORDER_STYLE_SOLID);

This function probably needs to be updated to take the enum class.

@@ -143,3 @@
>      if (allSides) {
>        aData->SetKeywordValueIfUnset(eCSSProperty_border_right_style,
> -                                    NS_STYLE_BORDER_STYLE_SOLID);

ditto

::: layout/painting/nsCSSRendering.cpp
@@ +1216,5 @@
>  
> +  uint8_t focusStyles[4] = { StyleBorderStyle::Dotted,
> +                             StyleBorderStyle::Dotted,
> +                             StyleBorderStyle::Dotted,
> +                             StyleBorderStyle::Dotted };

Update the type here

::: layout/painting/nsCSSRenderingBorders.cpp
@@ +392,3 @@
>    mozilla::Side sideV(GetVerticalSide(aCorner));
>    uint8_t styleH = mBorderStyles[sideH];
>    uint8_t styleV = mBorderStyles[sideV];

These types need to be updated.

@@ +1558,3 @@
>               "Style should be dashed or dotted.");
>  
>    uint8_t style = mBorderStyles[aSide];

This type needs to be updated.

@@ +2294,5 @@
>  
>    // Corner between dotted and others with radius=0 is drawn by side.
>    if (IsZeroSize(mBorderRadii[aCorner]) &&
> +      (styleV == StyleBorderStyle::Dotted ||
> +       styleH == StyleBorderStyle::Dotted)) {

You probably need to update these types.

@@ +2308,3 @@
>  
>    if (borderWidthH != borderWidthV || borderWidthH > 2.0f) {
>      uint8_t style = mBorderStyles[aSide];

update type
Attachment #8974770 - Flags: feedback+
Here is what I have so far. Converted the enum class. Will not build.
Attachment #8974770 - Attachment is obsolete: true
Comment on attachment 8974854 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

Review of attachment 8974854 [details] [diff] [review]:
-----------------------------------------------------------------

Having issues with generated code. Have not been able to find where the generated code is still creating the old constants. We think the problem is coming from https://searchfox.org/mozilla-central/rev/eb6c5214a63e20a3fff455e92c876287a8d2e188/servo/components/style/properties/gecko.mako.rs#2213-2225 . Emilio, do you know how I can go about fixing this?
Attachment #8974854 - Flags: feedback?(emilio)
Comment on attachment 8974854 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

Review of attachment 8974854 [details] [diff] [review]:
-----------------------------------------------------------------

You should be able to add gecko_enum_prefix="StyleBorderStyle" to:

  https://searchfox.org/mozilla-central/rev/eb6c5214a63e20a3fff455e92c876287a8d2e188/servo/components/style/properties/gecko.mako.rs#1557

Thanks for working on this!
Attachment #8974854 - Flags: feedback?(emilio) → feedback+
Here is what I have so far. Converted the enum class. Will not build.
Attachment #8974854 - Attachment is obsolete: true
Comment on attachment 8975551 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

Thank so much for the help so far! We're having another build failure pertaining to the Rust code. I added the enum prefix to the gecko.mako.rs file and the border.mako.rs file. Is there anything I can do to fix this build failure?

Here's the error we are getting:
> 1:32.28 error[E0004]: non-exhaustive patterns: `Auto` not covered
> 1:32.28     --> /Users/kristen/src/mozilla-unified/obj-x86_64-apple-darwin17.5.0.noindex/toolkit/library/x86_64-apple-darwin/release/build/style-b3afc1a052d9c14f/out/gecko_properties.rs:3664:15
> 1:32.28      |
> 1:32.28 3664 |         match self.gecko.mBorderStyle[0] {
> 1:32.29      |               ^^^^^^^^^^^^^^^^^^^^^^^^^^ pattern `Auto` not covered
> 1:32.29 error[E0004]: non-exhaustive patterns: `Auto` not covered
> 1:32.29     --> /Users/kristen/src/mozilla-unified/obj-x86_64-apple-darwin17.5.0.noindex/toolkit/library/x86_64-apple-darwin/release/build/style-b3afc1a052d9c14f/out/gecko_properties.rs:3836:15
> 1:32.29      |
> 1:32.29 3836 |         match self.gecko.mBorderStyle[1] {
> 1:32.29      |               ^^^^^^^^^^^^^^^^^^^^^^^^^^ pattern `Auto` not covered
> 1:32.29 error[E0004]: non-exhaustive patterns: `Auto` not covered
> 1:32.29     --> /Users/kristen/src/mozilla-unified/obj-x86_64-apple-darwin17.5.0.noindex/toolkit/library/x86_64-apple-darwin/release/build/style-b3afc1a052d9c14f/out/gecko_properties.rs:4008:15
> 1:32.29      |
> 1:32.29 4008 |         match self.gecko.mBorderStyle[2] {
> 1:32.29      |               ^^^^^^^^^^^^^^^^^^^^^^^^^^ pattern `Auto` not covered
> 1:32.29 error[E0004]: non-exhaustive patterns: `Auto` not covered
> 1:32.29     --> /Users/kristen/src/mozilla-unified/obj-x86_64-apple-darwin17.5.0.noindex/toolkit/library/x86_64-apple-darwin/release/build/style-b3afc1a052d9c14f/out/gecko_properties.rs:4180:15
> 1:32.29      |
> 1:32.29 4180 |         match self.gecko.mBorderStyle[3] {
> 1:32.29      |               ^^^^^^^^^^^^^^^^^^^^^^^^^^ pattern `Auto` not covered
> 1:32.29 warning: unreachable pattern
> 1:32.29      --> /Users/kristen/src/mozilla-unified/obj-x86_64-apple-darwin17.5.0.noindex/toolkit/library/x86_64-apple-darwin/release/build/style-b3afc1a052d9c14f/out/gecko_properties.rs:15441:25
> 1:32.29       |
> 1:32.29 15441 |                         _ => panic!("Found unexpected value in style struct for background_attachment property"),
> 1:32.29       |                         ^
> 1:32.29       |
> 1:32.29       = note: #[warn(unreachable_patterns)] on by default
> 1:32.29 error[E0004]: non-exhaustive patterns: `Auto` not covered
> 1:32.30      --> /Users/kristen/src/mozilla-unified/obj-x86_64-apple-darwin17.5.0.noindex/toolkit/library/x86_64-apple-darwin/release/build/style-b3afc1a052d9c14f/out/gecko_properties.rs:21809:15
> 1:32.30       |
> 1:32.30 21809 |         match self.gecko.mColumnRuleStyle {
> 1:32.30       |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^ pattern `Auto` not covered
Attachment #8975551 - Flags: feedback?(emilio)
Comment on attachment 8975551 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

Review of attachment 8975551 [details] [diff] [review]:
-----------------------------------------------------------------

ahh, so that is because "auto" is only a valid "outline-style" keyword, but not a valid "border-style" keyword. That's certainly somewhat annoying.

You should be able to use gecko_inexhaustive=True in the relevant keywords to add a panicking branch for unexpected values.

Other alternatives would be to split OutlineStyle and BorderStyle into two different enums, but that's not necessarily better.
Attachment #8975551 - Flags: feedback?(emilio) → feedback+
Converted NS_STYLE_BORDER_STYLE_* consts to enum class. Updated corresponding values to enum class.
Attachment #8975551 - Attachment is obsolete: true
Comment on attachment 8975989 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

Review of attachment 8975989 [details] [diff] [review]:
-----------------------------------------------------------------

::: layout/tables/nsTableFrame.cpp
@@ +5291,4 @@
>    uint32_t  ownerSide:2;    // LogicalSide (e.g eLogicalSideBStart, etc) of the border
>                              // owning the corner relative to the corner
>    uint32_t  ownerElem:3;    // elem type (e.g. eTable, eGroup, etc) owning the corner
> +  uint8_t   ownerStyle:8;   // border style of ownerElem

It's not super obvious here, but this is part of a bit field [1] so it's already a uint8_t. Changing the type will break the bit packing.

[1] http://en.cppreference.com/w/cpp/language/bit_field

@@ +5295,3 @@
>    uint32_t  subSide:2;      // side of border with subWidth relative to the corner
>    uint32_t  subElem:3;      // elem type (e.g. eTable, eGroup, etc) of sub owner
> +  StyleBorderStyle subStyle;// border style of subElem

And again this will break the bit packing, I'm not sure what the right thing to do here is. I'll let Emilio or another layout peer comment on that.
Comment on attachment 8975989 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

Review of attachment 8975989 [details] [diff] [review]:
-----------------------------------------------------------------

As erahm just noticed there is an issue with the enum class breaking the bit packing in nsTableFrame.cpp. Should I cast the enum class back to uint8 for these structs or is there a better way to go about it?
Attachment #8975989 - Flags: review?(emilio)
Comment on attachment 8975989 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

Review of attachment 8975989 [details] [diff] [review]:
-----------------------------------------------------------------

It seems straight-forward to avoid the casts and the size increase I think. This looks good other than that and the various nitpicks, thanks for fixing this! :)

::: layout/mathml/nsMathMLmtableFrame.cpp
@@ +57,2 @@
>      else
> +      return static_cast<int8_t>(StyleBorderStyle::None);

ugh, our mathml code :)

::: layout/painting/nsCSSRendering.cpp
@@ +1131,1 @@
>                                 outlineStyle, outlineStyle };

nit: Please fix indentation, here and below.

::: layout/painting/nsCSSRendering.h
@@ +577,4 @@
>    // Draw a border segment in the table collapsing border model without
>    // beveling corners
>    static void DrawTableBorderSegment(DrawTarget&   aDrawTarget,
> +                                     mozilla::StyleBorderStyle aBorderStyle,

nit: I'd either fix the function argument name indentation, or remove it from the rest of the arguments.

::: layout/painting/nsCSSRenderingBorders.cpp
@@ +390,4 @@
>    // |                         |
>    mozilla::Side sideH(GetHorizontalSide(aCorner));
>    mozilla::Side sideV(GetVerticalSide(aCorner));
> +  mozilla::StyleBorderStyle styleH = mBorderStyles[sideH];

nit: hmm, is the mozilla:: prefix needed here? doesn't look like it.

@@ -2289,4 @@
>      return;
>    }
>  
> -  Float styleH = mBorderStyles[sideH];

Wow this code was really confused about border styles :)

::: layout/painting/nsDisplayList.cpp
@@ +4934,4 @@
>  {
>    ContainerLayerParameters parameter;
>  
> +  mozilla::StyleBorderStyle outlineStyle = mFrame->Style()->StyleOutline()->mOutlineStyle;

nit: mozilla:: isn't needed in this file either I suspect.

::: layout/style/nsStyleStruct.h
@@ +1008,2 @@
>  {
> +  return (aStyle != mozilla::StyleBorderStyle::None &&

nit: stray parenthesis if you feel like fixing them :)

::: layout/tables/nsTableFrame.cpp
@@ +5039,4 @@
>    mozilla::Side physicalSide = aTableWM.PhysicalSide(aSide);
>    *aStyle = styleData->GetBorderStyle(physicalSide);
>  
> +  if ((StyleBorderStyle::None == *aStyle) ||

nit: I'd remove the parenthesis while here.

@@ +5150,5 @@
>    else if (aBorder1.width < aBorder2.width) {
>      firstDominates = false;
>    }
>    else if (aBorder1.width == aBorder2.width) {
> +    if (styleToPriority[static_cast<int8_t>(aBorder1.style)] < styleToPriority[static_cast<int8_t>(aBorder2.style)]) {

nit: maybe cast to uint8_t?

@@ +5291,4 @@
>    uint32_t  ownerSide:2;    // LogicalSide (e.g eLogicalSideBStart, etc) of the border
>                              // owning the corner relative to the corner
>    uint32_t  ownerElem:3;    // elem type (e.g. eTable, eGroup, etc) owning the corner
> +  uint8_t   ownerStyle:8;   // border style of ownerElem

I don't really have a strong opinion. The code was written long time ago (2002, wow), and it's written in a way that it these bits pack perfectly into a uint32_t, and the whole struct fits in a uint64_t.

This struct looks like it's allocated on the heap, and one per column, so there could be quite a few... If we want to keep the particular memory size of this struct it may be the easiest to just use uint32_t here and below and keep the casts.

These allocations seem very short-lived btw, so probably it doesn't matter that much nowadays.

I _think_ you can keep the same size without needing the casts though, by changing the bitfields to be uint16_t, and moving the two StyleBorderStyle members before the bitfield, like:

  StyleBorderStyle ownerStyle;
  StyleBorderStyle subStyle;
  uint16_t ownerSide: 2;
  uint16_t ownerElem: 3;
  uint16_t subSide: 2;
  uint16_t subElem: 3;
  // ...

That may be nicer. wdyt?

::: servo/components/style/properties/gecko.mako.rs
@@ +1555,5 @@
>  
>  <% border_style_keyword = Keyword("border-style",
> +                                  "none solid double dotted dashed hidden groove ridge inset outset",
> +                                  gecko_enum_prefix = "StyleBorderStyle",
> +                                  gecko_inexhaustive=True ) %>

nit: no space before the paren.

::: servo/components/style/properties/longhand/border.mako.rs
@@ +60,5 @@
>  
> +${helpers.gecko_keyword_conversion(Keyword("border-style",
> +                                   "none solid double dotted dashed hidden groove ridge inset outset",
> +                                   gecko_enum_prefix="StyleBorderStyle",
> +                                   gecko_inexhaustive=True ),

nit: there's an extra space here.
Attachment #8975989 - Flags: review?(emilio) → review+
Converted NS_STYLE_BORDER_STYLE_* consts to enum class. Updated corresponding values to enum class. Added StyleBorderStyle::Invalid for unset properties in nsTableFrame. reduced BCCornerInfo struct values to fit StyleBorderStyle values inside struct. Added defaults to switches that do not fully cover all instances of StyleBorderStyle.
Attachment #8975989 - Attachment is obsolete: true
Converted NS_STYLE_BORDER_STYLE_* consts to enum class. Updated corresponding values to enum class. Added StyleBorderStyle::Invalid for unset properties in nsTableFrame. reduced BCCornerInfo struct values to fit StyleBorderStyle values inside struct. Added defaults to switches that do not fully cover all instances of StyleBorderStyle.
Attachment #8977108 - Attachment is obsolete: true
Converted NS_STYLE_BORDER_STYLE_* consts to enum class. Updated corresponding values to enum class. Added StyleBorderStyle::Invalid for unset properties in nsTableFrame. reduced BCCornerInfo struct values to fit StyleBorderStyle values inside struct. Added defaults to switches that do not fully cover all instances of StyleBorderStyle.
Attachment #8977112 - Attachment is obsolete: true
Comment on attachment 8979307 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

I applied your recommendations as well as doing a sweep for any other namespace or indentation issues. Let me know if there is anything else to fix, and thank you so much for the help so far!
Attachment #8979307 - Flags: review?(emilio)
Comment on attachment 8979307 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

Review of attachment 8979307 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good with the bits below, thank you!

::: layout/painting/nsCSSRenderingBorders.cpp
@@ +330,3 @@
>        return ((aSides & ~(eSideBitsTop | eSideBitsLeft)) == 0 ||
>                (aSides & ~(eSideBitsBottom | eSideBitsRight)) == 0);
> +    default:

nit: Just:

default:
  return true;

And remove the return below?

@@ +434,5 @@
>        else if (aCorner == eCornerBottomRight)
>          return BorderColorStyleDark;
>        break;
> +    default:
> +      break;

ditto.

::: layout/painting/nsDisplayList.cpp
@@ +4934,4 @@
>  {
>    ContainerLayerParameters parameter;
>  
> +  StyleBorderStyle outlineStyle = mFrame->Style()->StyleOutline()->mOutlineStyle;

nit: While you're touching this line you can just use mFrame->StyleOutline()->mOutlineStyle, which is shorter.

::: layout/style/nsStyleConsts.h
@@ +322,5 @@
> +  Inset,
> +  Outset,
> +  Hidden,
> +  Auto,     // for outline-style only
> +  Invalid   // for use in nsTableFrame

Hmm, I'd prefer not to have this value, and just do something like:

const StyleBorderStyle kInvalidBorderStyle = static_cast<StyleBorderStyle>(255);

in nsTableFrame instead.

WDYT? Otherwise legitimate users of the enumeration need to deal with this bogus value, which is unfortunate.

::: layout/tables/nsTableFrame.cpp
@@ +8046,4 @@
>      auto param = action.mCreateWebRenderCommandsData.mBevelBorders[side];
>      LayoutDeviceRect borderRect;
>      nscolor borderColor = NS_RGBA(0, 0, 0, 255);
> +    StyleBorderStyle borderStyle = StyleBorderStyle::None;

nit: maybe use auto?
Attachment #8979307 - Flags: review?(emilio) → review+
Converted NS_STYLE_BORDER_STYLE_* consts to enum class. Updated corresponding values to enum class. Added StyleBorderStyle::Invalid for unset properties in nsTableFrame. reduced BCCornerInfo struct values to fit StyleBorderStyle values inside struct. Added defaults to switches that do not fully cover all instances of StyleBorderStyle.
Attachment #8979307 - Attachment is obsolete: true
Comment on attachment 8979642 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

That should be everything! Also fixed a few more namespace issues, so they should pop up in there. Thanks again for your help!
Attachment #8979642 - Flags: review?(emilio)
Comment on attachment 8979642 [details] [diff] [review]
Convert NS_STYLE_BORDER_STYLE_* to enum class

Review of attachment 8979642 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good, thanks!

Commit message nit: It shouldn't mention StyleBorderStyle::Invalid anymore

FWIW, if a reviewer has granted r+ already, I think unless the changes are substantive we tend to just land it instead of doing another round of review. But it doesn't matter much in any case.

Thanks a lot for fixing this!

::: layout/tables/nsTableFrame.h
@@ +38,4 @@
>  
>  struct BCPropertyData;
>  
> +const StyleBorderStyle kInvalidBorderStyle = static_cast<StyleBorderStyle>(255);

nit: No reason to be in the header, you may as well move it to the cpp file, right?
Attachment #8979642 - Flags: review?(emilio) → review+
Converted NS_STYLE_BORDER_STYLE_* consts to enum class. Updated corresponding values to enum class. reduced BCCornerInfo struct values to fit StyleBorderStyle values inside struct. Added defaults to switches that do not fully cover all instances of StyleBorderStyle.
Attachment #8979642 - Attachment is obsolete: true
What are the next steps to fixing this?
(It looks like the patch was ready to land, but never landed for some reason.)
Flags: needinfo?(kwright)
>(It looks like the patch was ready to land, but never landed for some reason.)
Hmm, that looks to be exactly what happened. I'll apply the patch and see what needs to be changed to go ahead and get this fixed.
Flags: needinfo?(kwright)
Converted NS_STYLE_BORDER_STYLE_* consts to enum class. Updated corresponding values to enum class. reduced BCCornerInfo struct values to fit StyleBorderStyle values inside struct. Added defaults to switches that do not fully cover all instances of StyleBorderStyle.
Attachment #8980096 - Attachment is obsolete: true
Comment on attachment 9026506 [details] [diff] [review]
Conversion from NS_STYLE_BORDER_STYLE_* macro to StyleBorderStyle::* enum class

Review of attachment 9026506 [details] [diff] [review]:
-----------------------------------------------------------------

This is a rebase and update of an old patch. I flagged you in case you would like to take a look at it first.
Attachment #9026506 - Flags: review?(emilio)
Comment on attachment 9026506 [details] [diff] [review]
Conversion from NS_STYLE_BORDER_STYLE_* macro to StyleBorderStyle::* enum class

Review of attachment 9026506 [details] [diff] [review]:
-----------------------------------------------------------------

I didn't review it super-carefully assuming it's been a mostly-trivial rebase, but looks fine, thanks for rebasing it!
Attachment #9026506 - Flags: review?(emilio) → review+
Keywords: checkin-needed
When applying this patch, I've received hunks failed on the following:

applying base-0ec971862595
patching file layout/painting/nsDisplayList.cpp
Hunk #2 FAILED at 9490
1 out of 2 hunks FAILED -- saving rejects to file layout/painting/nsDisplayList.cpp.rej
patching file layout/style/ServoBindings.toml
Hunk #2 FAILED at 207
1 out of 2 hunks FAILED -- saving rejects to file layout/style/ServoBindings.toml.rej
patching file layout/style/nsCSSProps.cpp
Hunk #1 succeeded at 190 with fuzz 1 (offset -10 lines).
patching file servo/components/style/properties/longhands/border.mako.rs
Hunk #1 FAILED at 62
1 out of 1 hunks FAILED -- saving rejects to file servo/components/style/properties/longhands/border.mako.rs.rej
patch failed, unable to continue (try -v)
patch failed, rejects left in working directory
errors during apply, please fix and qrefresh base-0ec971862595


Kristen: can you please take a look?
Flags: needinfo?(kwright)
Keywords: checkin-needed
(In reply to Cristian Brindusan [:cbrindusan] from comment #27)
> applying base-0ec971862595
> patching file layout/painting/nsDisplayList.cpp
> Hunk #2 FAILED at 9490
> 1 out of 2 hunks FAILED -- saving rejects to file
> layout/painting/nsDisplayList.cpp.rej
> patching file layout/style/ServoBindings.toml
> Hunk #2 FAILED at 207
> 1 out of 2 hunks FAILED -- saving rejects to file
> layout/style/ServoBindings.toml.rej
> patching file layout/style/nsCSSProps.cpp
> Hunk #1 succeeded at 190 with fuzz 1 (offset -10 lines).
> patching file servo/components/style/properties/longhands/border.mako.rs
> Hunk #1 FAILED at 62
> 1 out of 1 hunks FAILED -- saving rejects to file
> servo/components/style/properties/longhands/border.mako.rs.rej
Looks like all of these files have been changed recently. I'll rebase again and update the patch.
Flags: needinfo?(kwright)
Converted NS_STYLE_BORDER_STYLE_* consts to enum class. Updated corresponding values to enum class. reduced BCCornerInfo struct values to fit StyleBorderStyle values inside struct. Added defaults to switches that do not fully cover all instances of StyleBorderStyle.
Attachment #9026506 - Attachment is obsolete: true
Keywords: checkin-needed
Pushed by dluca@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/298dbb648831
Conversion from NS_STYLE_BORDER_STYLE_* macro to StyleBorderStyle::* enum class r=emilio
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/298dbb648831
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla65
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: