Move uint8_clamped into ObjectImpl.{h,cpp}

RESOLVED FIXED in mozilla14

Status

()

Core
JavaScript Engine
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: Waldo, Assigned: Waldo)

Tracking

Trunk
mozilla14
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

Created attachment 613447 [details] [diff] [review]
Patch

The new element-property split entails moving the typed array elements code into the base object representation.  To do that, I need access to uint8_clamped in ObjectImpl.h.  The easiest way to get that is to move the class and related methods into it.

(Technically we could do the value-clamping behavior in a different way, that didn't involve overloading operator= on a uint8_clamped struct.  That might even be preferable, for clarity, and might read more naturally if we make the typed array element-setting code slightly more split-up, rather than having it all be in a single method.  But for now, it's easiest to leave the current tricks alone and just get 'er done with the current implementation trick.)
Attachment #613447 - Flags: review?(sphink)
Comment on attachment 613447 [details] [diff] [review]
Patch

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

Looks fine to me. It was trivial to rebase on top of this, too, so feel free to land whenever.
Attachment #613447 - Flags: review?(sphink) → review+
Thanks!

https://hg.mozilla.org/integration/mozilla-inbound/rev/ab4a85bc480a
Target Milestone: --- → mozilla14
https://hg.mozilla.org/mozilla-central/rev/ab4a85bc480a
Status: ASSIGNED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.