mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 22:57:44 +00:00
LibJS: Update comments for Annex B changes to IsLooselyEqual
This is an editorial change in the ECMA-262 spec.
See: da3d674
This commit is contained in:
parent
17fb40bc42
commit
257375f54c
1 changed files with 3 additions and 2 deletions
|
@ -1419,11 +1419,12 @@ ThrowCompletionOr<bool> is_loosely_equal(GlobalObject& global_object, Value lhs,
|
|||
|
||||
// 4. NOTE: This step is replaced in section B.3.6.2.
|
||||
// B.3.6.2 Changes to IsLooselyEqual, https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
|
||||
// 1. If Type(x) is Object and x has an [[IsHTMLDDA]] internal slot and y is either null or undefined, return true.
|
||||
// 4. Perform the following steps:
|
||||
// a. If Type(x) is Object and x has an [[IsHTMLDDA]] internal slot and y is either null or undefined, return true.
|
||||
if (lhs.is_object() && lhs.as_object().is_htmldda() && rhs.is_nullish())
|
||||
return true;
|
||||
|
||||
// 2. If x is either null or undefined and Type(y) is Object and y has an [[IsHTMLDDA]] internal slot, return true.
|
||||
// b. If x is either null or undefined and Type(y) is Object and y has an [[IsHTMLDDA]] internal slot, return true.
|
||||
if (lhs.is_nullish() && rhs.is_object() && rhs.as_object().is_htmldda())
|
||||
return true;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue