Closed
Bug 555807
Opened 14 years ago
Closed 14 years ago
typed array native constructor fix
Categories
(Core :: JavaScript Engine, defect)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
People
(Reporter: vlad, Unassigned)
Details
(Whiteboard: fixed-in-tracemonkey)
Attachments
(1 file)
782 bytes,
patch
|
jorendorff
:
review+
|
Details | Diff | Splinter Review |
Wrong args were being passed here; this can only be called from native code and is currently not used anywhere (was added for completeness, since otherwise it's impossible to create typed arrays with buffers from native code).
Attachment #435694 -
Flags: review?(jorendorff)
Comment 1•14 years ago
|
||
Comment on attachment 435694 [details] [diff] [review] fix Looks good, but a few more comments about this function: The return value from js_NewNumberInRootedValue should be checked. (Also in js_CreateArrayBuffer.) And there's a macro to help you say what you mean here: - /* if byteoffset is -1, length must be -1 */ - JS_ASSERT(length < 0 || byteoffset >= 0); + JS_ASSERT_IF(byteoffset < 0, length < 0);
Comment 2•14 years ago
|
||
Comment on attachment 435694 [details] [diff] [review] fix r=me with the comments addressed.
Attachment #435694 -
Flags: review?(jorendorff) → review+
Reporter | ||
Comment 3•14 years ago
|
||
http://hg.mozilla.org/tracemonkey/rev/6606d03df5cc with comments fixed. Thanks!
Whiteboard: fixed-in-tracemonkey
Comment 4•14 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/6606d03df5cc
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•