style: paint-order parsing has off-by-one error.

A couple of firefox only WPT failure caused by this off-by-one bug.

Differential Revision: https://phabricator.services.mozilla.com/D35630
This commit is contained in:
violet 2019-06-24 04:07:42 +00:00 committed by Emilio Cobos Álvarez
parent 2fba62aba9
commit 5db88db8fc
No known key found for this signature in database
GPG key ID: E1152D0994E4BF8A

View file

@ -200,7 +200,7 @@ impl Parse for SVGPaintOrder {
// fill in rest
for i in pos..PAINT_ORDER_COUNT {
for paint in 0..PAINT_ORDER_COUNT {
for paint in 1..(PAINT_ORDER_COUNT + 1) {
// if not seen, set bit at position, mark as seen
if (seen & (1 << paint)) == 0 {
seen |= 1 << paint;