[Meta] Mark DOM method arguments optional per the DOM4 spec

RESOLVED FIXED

Status

()

Core
DOM
RESOLVED FIXED
6 years ago
6 years ago

People

(Reporter: sicking, Assigned: mjschranz)

Tracking

Trunk
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Arguments which are optional in DOM4 but not in our implementation:

Node.cloneNode(optional boolean deep);  (Note, defaults to true)
Document.createNodeIterator(Node root, optional unsigned long whatToShow,
                            optional NodeFilter? filter);
Document.createTreeWalker(Node root, optional unsigned long whatToShow,
                          optional NodeFilter? filter);

Comment 1

6 years ago
The latter two methods used to take also bool aEntityReferenceExpansion as parameter.
We could perhaps make also that optional, or just leave it out.
I think we should just leave it out and make .expandEntityReferences return false.

(We should even make .expandEntityReferences warn if used and then remove it a release later. But that might be a separate bug)
Actually, we might even be able to remove .expandEntityReferences right away given that it's a property. So we won't throw if people use it, just return a falsy value (undefined).
OS: Mac OS X → All
Hardware: x86 → All

Updated

6 years ago
Depends on: 698381

Comment 4

6 years ago
Although the changes will be small, I'd prefer making them in separate patches/bugs so that if
some of them isn't web compatible, it can be easily backed out.
Summary: Mark DOM method arguments optional per the DOM4 spec → [Meta] Mark DOM method arguments optional per the DOM4 spec

Updated

6 years ago
Depends on: 698384

Updated

6 years ago
Depends on: 698385
(Assignee)

Updated

6 years ago
Assignee: nobody → schranz.m
(Assignee)

Comment 5

6 years ago
I figure that since I'm working on 698384 and 698385 I might as well go for this one as well, unless someone objects.
Status: NEW → ASSIGNED
(Assignee)

Comment 6

6 years ago
All three of the "sub tickets" 698381 698384 and 698385 are now resolved and have landed.
Status: ASSIGNED → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.