Closed
Bug 1096260
Opened 10 years ago
Closed 10 years ago
some callers of nsIFrame::ComputeSize still pass a bool for the last parameter instead of a flags word
Categories
(Core :: Layout: Block and Inline, defect)
Core
Layout: Block and Inline
Tracking
()
RESOLVED
FIXED
mozilla36
People
(Reporter: jfkthame, Assigned: jfkthame)
References
Details
Attachments
(1 file)
This parameter was changed in bug 732610, but some callers were apparently missed (or have been added since?), and so they still pass a literal bool. This compiles without complaint, as the bool automatically gets promoted to uint32_t, but makes the code misleading and error-prone. See callers in nsFrame::BoxReflow(), FloatMarginISize(), and ChildShrinkWrapWidth(). I suggest we change the flags parameter from plain uint32_t to a typed enum, which will force callers to explicitly pass the correct type.
Assignee | ||
Comment 1•10 years ago
|
||
Attachment #8519880 -
Flags: review?(dholbert)
Assignee | ||
Updated•10 years ago
|
Assignee: nobody → jfkthame
Status: NEW → ASSIGNED
Comment 2•10 years ago
|
||
Comment on attachment 8519880 [details] [diff] [review] Convert flags parameter of nsIFrame::ComputeSize from uint32_t to a typed enum, and update callers accordingly. Thanks for catching this!
Attachment #8519880 -
Flags: review?(dholbert) → review+
Updated•10 years ago
|
Version: unspecified → Trunk
Assignee | ||
Comment 3•10 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/be1f8816683e
Target Milestone: --- → mozilla36
Comment 4•10 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/be1f8816683e
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•