From 97f0a958bc1dcb98265d116bafdc80ae1b059823 Mon Sep 17 00:00:00 2001 From: Anne van Kesteren Date: Mon, 14 Mar 2016 14:25:57 +0100 Subject: [PATCH] Restore Node.prototype.isSameNode() Fixes https://www.w3.org/Bugs/Public/show_bug.cgi?id=27424. --- dom.bs | 14 +++++++------- dom.html | 12 ++++++++---- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/dom.bs b/dom.bs index c4889a941..8164bcf46 100644 --- a/dom.bs +++ b/dom.bs @@ -2981,6 +2981,7 @@ interface Node : EventTarget { [NewObject] Node cloneNode(optional boolean deep = false); boolean isEqualNode(Node? otherNode); + boolean isSameNode(Node? otherNode); // historical alias of === const unsigned short DOCUMENT_POSITION_DISCONNECTED = 0x01; const unsigned short DOCUMENT_POSITION_PRECEDING = 0x02; @@ -3633,11 +3634,12 @@ A node A index. -The -isEqualNode(otherNode) -method must return true if node is not null and -context object equals -otherNode, and false otherwise. +

The isEqualNode(otherNode) method, when +invoked, must return true if otherNode is non-null and context object +equals otherNode, and false otherwise. + +

The isSameNode(otherNode) method, when +invoked, must return true if otherNode is context object, and false otherwise. @@ -8895,8 +8897,6 @@ Interface members:

  • getFeature()
  • getUserData()
  • setUserData() - -
  • isSameNode()
    {{Document}} diff --git a/dom.html b/dom.html index aedaefa6b..1722d394a 100644 --- a/dom.html +++ b/dom.html @@ -69,7 +69,7 @@

    DOM

    -

    Living Standard — Last Updated

    +

    Living Standard — Last Updated

    Participate: @@ -1765,6 +1765,7 @@

    Node cloneNode(optional boolean deep = false); boolean isEqualNode(Node? otherNode); + boolean isSameNode(Node? otherNode); // historical alias of === const unsigned short DOCUMENT_POSITION_DISCONNECTED = 0x01; const unsigned short DOCUMENT_POSITION_PRECEDING = 0x02; @@ -2085,7 +2086,10 @@

    children.
  • Each child of A equals the child of B at the identical index. -

    The isEqualNode(otherNode) method must return true if node is not null and context object equals otherNode, and false otherwise.

    +

    The isEqualNode(otherNode) method, when +invoked, must return true if otherNode is non-null and context object equals otherNode, and false otherwise.

    +

    The isSameNode(otherNode) method, when +invoked, must return true if otherNode is context object, and false otherwise.


  • @@ -4431,7 +4435,6 @@

    getFeature()
  • getUserData()
  • setUserData() -
  • isSameNode()
    Document
    @@ -4983,7 +4986,7 @@

    isElementContentWhitespace, in §8.2
  • isEqualNode(otherNode), in §4.4
  • isPointInRange(node, offset), in §5.2 -
  • isSameNode(), in §8.2 +
  • isSameNode(otherNode), in §4.4
  • isSupported, in §8.2
  • isTrusted, in §3.2
  • @@ -5683,6 +5686,7 @@

    I [NewObject] Node cloneNode(optional boolean deep = false); boolean isEqualNode(Node? otherNode); + boolean isSameNode(Node? otherNode); // historical alias of === const unsigned short DOCUMENT_POSITION_DISCONNECTED = 0x01; const unsigned short DOCUMENT_POSITION_PRECEDING = 0x02;