Closed Bug 839979 Opened 11 years ago Closed 11 years ago

Implement Object.is

Categories

(Core :: JavaScript Engine, defect)

x86
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla22

People

(Reporter: bruant.d, Assigned: evilpie)

References

(Blocks 1 open bug)

Details

(Keywords: dev-doc-complete)

Attachments

(1 file, 1 obsolete file)

Per TC39 January 2013 meeting [1], is/isnt are out as operators, but Object.is remains (no need for Object.isnt, ! is enough for negation)

[1] https://github.com/rwldrn/tc39-notes/blob/master/es6/2013-01/jan-29.md#41-isisnt-operators
Blocks: es6
I implemented these as |is| and |isnt| before, taking.
Assignee: general → evilpies
Status: NEW → ASSIGNED
Attached patch v1 (obsolete) — Splinter Review
I took some ideas for tests from bug 715359. The rest is pretty straight forward, except maybe the args.length() < 2, because this is actually not clearly defined. So I made a post to es-discuss.
Attachment #725793 - Flags: review?(jorendorff)
For some reason I confused myself more than I should have here. The args.length() < 2 should not return false here. New patch coming up.
Attached patch v2Splinter Review
This now has the right behavior.
Attachment #725793 - Attachment is obsolete: true
Attachment #725793 - Flags: review?(jorendorff)
Attachment #725938 - Flags: review?(jorendorff)
Comment on attachment 725938 [details] [diff] [review]
v2

Review of attachment 725938 [details] [diff] [review]:
-----------------------------------------------------------------

Beautiful!
Attachment #725938 - Flags: review?(jorendorff) → review+
Keywords: dev-doc-needed
https://hg.mozilla.org/mozilla-central/rev/a321bf04c39b
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla22
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: