Commit graph

13 commits

Author SHA1 Message Date
Simon Sapin
1d38bc0419 Fix some new warnings 2019-06-22 14:59:09 +02:00
Emilio Cobos Álvarez
a109fbb7c8 style: Use ArcSlice for quotes.
This saves the intermediate allocation.

Differential Revision: https://phabricator.services.mozilla.com/D30546
2019-05-29 16:14:10 +02:00
Emilio Cobos Álvarez
ab8776a144 style: Use OwnedSlice in the specified and computed values of most vector properties.
This is just a refactor in the right direction. Eventual goal is:

 * All inherited properties use ArcSlice<>.
 * All reset properties use OwnedSlice<> (or ThinVec<>).

No conversion happens at all, so we can remove all that glue, and also
compute_iter and co.

Of course there's work to do, but this is a step towards that.

Differential Revision: https://phabricator.services.mozilla.com/D30127
2019-05-29 16:14:07 +02:00
Emilio Cobos Álvarez
0d5c4481b8 style: Introduce ArcSlice, a small wrapper over ThinArc but without an explicit header.
We could make the header PhantomData or something, but then we wouldn't be able
to bind to C++, since C++ doesn't have ZSTs. So add a canary instead to add a
runtime check of stuff being sane.

Differential Revision: https://phabricator.services.mozilla.com/D30133
2019-05-10 12:43:04 +02:00
Emilio Cobos Álvarez
4b07af2240 style: Make cssPropertySupportsType take an enum.
Differential Revision: https://phabricator.services.mozilla.com/D22427
2019-03-27 14:29:09 +01:00
Jan Andre Ikenmeyer
1d6fe65401
Update MPL license to https (part 4) 2018-11-19 14:47:27 +01:00
chansuke
a2fc2ae517 Format component of style_traits 2018-09-08 13:28:13 +09:00
Emilio Cobos Álvarez
2c0a19e517
style: Move some parsing-only attributes to use #[parse(..)] instead of #[css(..)].
I need to admit I'm ambivalent about this one :).

Bug: 1466609
Reviewed-by: xidorn
MozReview-Commit-ID: F1jlfnQKXwo
2018-06-12 12:15:10 -07:00
Emilio Cobos Álvarez
c508d8576d
style: Move represents_keyword to the css attributes.
Bug: 1457635
Reviewed-by: xidorn
MozReview-Commit-ID: 21yuU4h34AQ
2018-05-05 16:20:22 +02:00
Emilio Cobos Álvarez
292f899631
style: Fix tidy issues and Servo build. 2018-04-29 05:09:43 +02:00
Xidorn Quan
0f7f9eebc0
style: Add some attributes for SpecifiedValueInfo to help deriving more from types.
Bug: 1434130
Reviewed-by: emilio
MozReview-Commit-ID: IyohSTbUO31
2018-04-29 03:28:48 +02:00
Xidorn Quan
26c3aeda97
style: Add collect_values function to SpecifiedValueInfo trait for collecting possible values.
This is the basic structure of the stuff. Following patches will fill
the gap between Gecko and Servo on value generating, and finally hook
it into InspectorUtils.

Bug: 1434130
Reviewed-by: emilio
MozReview-Commit-ID: KNLAfFBiY6e
2018-04-29 03:28:40 +02:00
Xidorn Quan
7fe7b2ffb1
style: Add a ValueInfo trait for exposing types needed by devtools.
Most of types just derive it using proc_macro directly. Some of value
types need manual impl.

In my current plan, this new trait will be used in bug 1434130 to expose
values as well.

Bug: 1455576
Reviewed-by: emilio
MozReview-Commit-ID: LI7fy45VkRw
2018-04-29 03:28:34 +02:00