Closed Bug 985955 Opened 6 years ago Closed 6 years ago

accessible/src/base/StyleInfo.cpp:53:11: warning: enumeration value 'eStyleUnit_FlexFraction' not handled in switch [-Wswitch]

Categories

(Core :: Disability Access APIs, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla31

People

(Reporter: dholbert, Assigned: dholbert)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

New build warning:
{
accessible/src/base/StyleInfo.cpp:53:11: warning: enumeration value 'eStyleUnit_FlexFraction' not handled in switch [-Wswitch]
}

Source code in question:
http://mxr.mozilla.org/mozilla-central/source/accessible/src/base/StyleInfo.cpp#45

This function is about text-indent, and FlexFraction is a unit used only in grid sizing, so we should add it to the bunch of case statements that do nothing here.
Assignee: nobody → dholbert
Status: NEW → ASSIGNED
Also:
{
TextAttrs.cpp:815:11: warning: enumeration value 'eStyleUnit_FlexFraction' not handled in switch [-Wswitch]
}
Attached patch fixSplinter Review
The first of these is checking StyleText()->mTextIndent; the second is checking StyleTextReset()->mVerticalAlign.

Neither of those can take eStyleUnit_FlexFraction. (Only "grid-template-rows" and "-columns" takes this unit currently.)

So, it's appropriate to add this unit to the do-nothing group in these switch statements.
Attachment #8394156 - Flags: review?(trev.saunders)
Comment on attachment 8394156 [details] [diff] [review]
fix

thanks!
Attachment #8394156 - Flags: review?(trev.saunders) → review+
https://hg.mozilla.org/mozilla-central/rev/b2db7e161af3
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla31
You need to log in before you can comment on or make changes to this bug.