You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm not enough of a Unicode expert to say if "" and "\u0000" are "canonically equivalent" but the inconsistency between firefox and nodejs suggests that one of the two projects has a bug. I reported to firefox here: https://bugzilla.mozilla.org/show_bug.cgi?id=1629547
The text was updated successfully, but these errors were encountered:
What steps will reproduce the bug?
Evaluate
"".localeCompare("\u0000");
What is the expected behavior?
Firefox reports 0.
ECMA-402 says "The method is required to return +0 when comparing Strings that are considered canonically equivalent by the Unicode standard." https://ecma-international.org/ecma-402/6.0/index.html#sec-collator-comparestrings
What do you see instead?
node reports -1
Additional information
I'm not enough of a Unicode expert to say if "" and "\u0000" are "canonically equivalent" but the inconsistency between firefox and nodejs suggests that one of the two projects has a bug. I reported to firefox here: https://bugzilla.mozilla.org/show_bug.cgi?id=1629547
The text was updated successfully, but these errors were encountered: