duplication between setting |inherited| and Check*Callback

NEW
Unassigned

Status

()

Core
CSS Parsing and Computation
11 years ago
11 years ago

People

(Reporter: dbaron, Unassigned)

Tracking

Trunk
Future
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

11 years ago
In bug 388548 comment 3, bzbarsky wrote:
> I really wish we didn't duplicate logic like this between the check
> callbacks and the actual computation.  :(

We can avoid this duplication by initializing |aInherited| better and not setting it in nsRuleNode::Compute*Data in the cases where it's already set based on that initialization.  We should probably have some assertions to verify things, though.
(Reporter)

Updated

11 years ago
Assignee: dbaron → nobody
Status: ASSIGNED → NEW
Target Milestone: mozilla1.9beta1 → Future
(Reporter)

Comment 1

11 years ago
Created attachment 273054 [details] [diff] [review]
broken patch

Here's what I was thinking, roughly.  This achieves the assertions by making parentdata_ null when we shouldn't be using it, but there are a bunch of places where we dereference things in parentData because we might use them.  So it crashes, probably because of that, although I haven't checked.

I'm not going to work further on this now; I can't justify making it a priority.
You need to log in before you can comment on or make changes to this bug.