Closed
Bug 730676
Opened 13 years ago
Closed 13 years ago
Add CallArgs::hasDefined convenience method
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
FIXED
mozilla13
People
(Reporter: jorendorff, Assigned: jorendorff)
Details
Attachments
(1 file)
16.84 KB,
patch
|
luke
:
review+
|
Details | Diff | Splinter Review |
See bug 726223 comment 5.
Assignee | ||
Comment 1•13 years ago
|
||
Assignee: general → jorendorff
Attachment #600771 -
Flags: review?(luke)
![]() |
||
Comment 2•13 years ago
|
||
Comment on attachment 600771 [details] [diff] [review]
v1
Review of attachment 600771 [details] [diff] [review]:
-----------------------------------------------------------------
Great
::: js/src/builtin/RegExp.cpp
@@ +344,5 @@
> * See ECMAv5 15.10.3.1.
> */
> + if (args.length() >= 1 &&
> + IsObjectWithClass(args[0], ESClass_RegExp, cx) &&
> + !args.hasDefined(1))
How about
args.hasDefined(0) &&
IsObjectWithClass(args[0], ESClass_RegExp, cx) &&
!args.hasDefined(1)
? (Unnecessary 'undefined' test, but I think this shouldn't be significant here.)
::: js/src/jsobj.cpp
@@ +2400,3 @@
> if (!obj)
> + return false;
> + args.rval().setObject(*obj); /* Root and prepare for eventual return. */
Pre-existing, but args.rval() should only be assigned to after the last observable operation.
Attachment #600771 -
Flags: review?(luke) → review+
Assignee | ||
Comment 3•13 years ago
|
||
Comment 4•13 years ago
|
||
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla13
You need to log in
before you can comment on or make changes to this bug.
Description
•