Re: [matrix][cssom-view] DOMPoint, DOMPointLiteral definitions

On 9/25/13 4:48 AM, Robert O'Callahan wrote:
> On Wed, Sep 25, 2013 at 5:42 PM, Boris Zbarsky <bzbarsky@mit.edu
> <mailto:bzbarsky@mit.edu>> wrote:
>
>     As in, do we really just want to have an immutable DOMRect type and
>     a DOMRectLiteral dictionary, and have things like
>     getBoundingClientRect() return the latter, say?
>
>
> The only problem with that is we can't have methods on dictionaries. At
> the implementation level we probably have to reify all the attributes,
> too, which is sort of annoying ... a rectangle only needs 4 scalar
> values, but the dictionary version would need at least 6.

Right.  And using a dictionary here would mean the caller could make it 
self-inconsistent...

OK, sounds like this is not something we should do.  Was just worth 
checking.

-Boris

Received on Wednesday, 25 September 2013 14:29:24 UTC