Bug 149529 - Optimize Range's lengthOfContentsInNode() for DocumentType Nodes
Summary: Optimize Range's lengthOfContentsInNode() for DocumentType Nodes
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: Other
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL: https://dom.spec.whatwg.org/#concept-...
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-24 10:09 PDT by Chris Dumez
Modified: 2015-09-24 10:25 PDT (History)
5 users (show)

See Also:


Attachments
Patch (3.14 KB, patch)
2015-09-24 10:18 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2015-09-24 10:09:09 PDT
Optimize Range's lengthOfContentsInNode() for DocumentType Nodes:
https://dom.spec.whatwg.org/#concept-node-length

We currently call Node::countChildNodes() unnecessarily on DocumentType Nodes instead of simply returning 0.
Comment 1 Chris Dumez 2015-09-24 10:18:54 PDT
Created attachment 261873 [details]
Patch
Comment 2 Chris Dumez 2015-09-24 10:25:31 PDT
Comment on attachment 261873 [details]
Patch

Clearing flags on attachment: 261873

Committed r190208: <http://trac.webkit.org/changeset/190208>
Comment 3 Chris Dumez 2015-09-24 10:25:36 PDT
All reviewed patches have been landed.  Closing bug.