Please sign in to comment.
style: Derive more length stuff, and shrink MaxLength / MozLength's r…
…epr(C) representation. This patch: * Makes LengthPercentageOrAuto generic, and removes a bunch of code fo LengthPercentageOrNone, which was used only for servo and now can use the normal MaxLength (with a cfg() guard for the ExtremumLength variant). * Shrinks MaxLength / MozLength's repr(C) reperesentation by reducing enum nesting. The shrinking is in preparation for using them from C++ too, though that'd be a different bug. * Moves NonNegative usage to the proper places so that stuff for them can be derived. I did this on top of bug 1523071 to prove both that it could be possible and that stuff wasn't too messy. It got a bit messy, but just because of a bug I had fixed in bindgen long time ago already, so this updates bindgen's patch version to grab a fix instead of ugly workarounds :) Differential Revision: https://phabricator.services.mozilla.com/D17762
- Loading branch information...
Showing with 334 additions and 517 deletions.
- +1 −1 components/style/cbindgen.toml
- +6 −5 components/style/gecko/conversions.rs
- +25 −33 components/style/gecko/values.rs
- +2 −3 components/style/properties/gecko.mako.rs
- +17 −31 components/style/properties/longhands/position.mako.rs
- +6 −6 components/style/properties/properties.mako.rs
- +9 −8 components/style/stylesheets/viewport_rule.rs
- +1 −51 components/style/values/animated/length.rs
- +5 −4 components/style/values/computed/background.rs
- +67 −157 components/style/values/computed/length.rs
- +1 −1 components/style/values/computed/mod.rs
- +6 −6 components/style/values/generics/background.rs
- +94 −5 components/style/values/generics/length.rs
- +4 −2 components/style/values/specified/background.rs
- +6 −6 components/style/values/specified/gecko.rs
- +83 −197 components/style/values/specified/length.rs
- +1 −1 components/style/values/specified/mod.rs
Oops, something went wrong.