GroupRuleRuleList::GetParentObject should return a ServoStyleSheet too

RESOLVED INVALID

Status

()

Core
CSS Parsing and Computation
RESOLVED INVALID
2 months ago
2 months ago

People

(Reporter: heycam, Assigned: heycam)

Tracking

(Blocks: 1 bug)

Trunk
Points:
---

Firefox Tracking Flags

(firefox59 affected)

Details

MozReview Requests

()

Submitter Diff Changes Open Issues Last Updated
Loading...
Error loading review requests:

Attachments

(1 attachment)

Comment hidden (empty)
Assignee: nobody → cam
Status: NEW → ASSIGNED
Comment hidden (mozreview-request)

Comment 3

2 months ago
mozreview-review
Comment on attachment 8931214 [details]
Bug 1420039 - Return a ServoStyleSheet from GroupRuleRuleList::GetParentObject when the rule is Servo-backed.

https://reviewboard.mozilla.org/r/202316/#review207682


C/C++ static analysis found 1 defect in this patch.

You can run this analysis locally with: `./mach static-analysis check path/to/file.cpp`


::: layout/style/GroupRule.cpp:35
(Diff revision 1)
>  class GroupRuleRuleList final : public dom::CSSRuleList
>  {
>  public:
>    explicit GroupRuleRuleList(GroupRule *aGroupRule);
>  
> -  virtual CSSStyleSheet* GetParentObject() override;
> +  virtual StyleSheet* GetParentObject() override;

Warning: 'virtual' is redundant since the function is already declared 'override' [clang-tidy: modernize-use-override]
Comment hidden (mozreview-request)
I don't understand why this change is necessary. GroupRuleRuleList is only used inside GeckoGroupRuleRules, and thus it should never have a Servo style sheet. Why does it need to return StyleSheet rather than the more specific CSSStyleSheet?
Flags: needinfo?(cam)

Comment 6

2 months ago
mozreview-review
Comment on attachment 8931214 [details]
Bug 1420039 - Return a ServoStyleSheet from GroupRuleRuleList::GetParentObject when the rule is Servo-backed.

https://reviewboard.mozilla.org/r/202316/#review207846
Attachment #8931214 - Flags: review?(xidorn+moz)
Oh, my mistake.
Status: ASSIGNED → RESOLVED
Last Resolved: 2 months ago
Flags: needinfo?(cam)
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.