Bug 176287 - DOMMatrix/DOMMatrixReadOnly validation is incorrect for NaN values
Summary: DOMMatrix/DOMMatrixReadOnly validation is incorrect for NaN values
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Sam Weinig
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2017-09-02 19:30 PDT by Sam Weinig
Modified: 2017-09-27 12:58 PDT (History)
6 users (show)

See Also:


Attachments
Patch (4.52 KB, patch)
2017-09-02 19:33 PDT, Sam Weinig
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sam Weinig 2017-09-02 19:30:39 PDT
DOMMatrix/DOMMatrixReadOnly validation is incorrect for NaN values
Comment 1 Sam Weinig 2017-09-02 19:33:55 PDT
Created attachment 319751 [details]
Patch
Comment 2 Chris Dumez 2017-09-02 20:35:03 PDT
Comment on attachment 319751 [details]
Patch

r=me
Comment 3 WebKit Commit Bot 2017-09-02 21:05:03 PDT
Comment on attachment 319751 [details]
Patch

Clearing flags on attachment: 319751

Committed r221545: <http://trac.webkit.org/changeset/221545>
Comment 4 WebKit Commit Bot 2017-09-02 21:05:05 PDT
All reviewed patches have been landed.  Closing bug.
Comment 5 Simon Fraser (smfr) 2017-09-05 08:54:09 PDT
Comment on attachment 319751 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=319751&action=review

> Source/WebCore/css/DOMMatrixReadOnly.cpp:99
> +static bool sameValueZero(double a, double b)

It may be in the spec, but I find the name of this very confusing, and not at all memorable. Also, should it go into MathExtras.h?
Comment 6 Sam Weinig 2017-09-05 10:34:18 PDT
(In reply to Simon Fraser (smfr) from comment #5)
> Comment on attachment 319751 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=319751&action=review
> 
> > Source/WebCore/css/DOMMatrixReadOnly.cpp:99
> > +static bool sameValueZero(double a, double b)
> 
> It may be in the spec, but I find the name of this very confusing, and not
> at all memorable. Also, should it go into MathExtras.h?

I agree the name's not good. Have any ideas for a better one? I'm not a fan of putting things in MathExtras.h (or other shared places) that are only used in one place (though I admit its a bit of a chicken and the egg. If it's not in the shared place, how will people know about it?)

Happy to move it if we can come up with a non-terrible name.
Comment 7 Simon Fraser (smfr) 2017-09-05 11:12:27 PDT
(In reply to Sam Weinig from comment #6)
> (In reply to Simon Fraser (smfr) from comment #5)
> > Comment on attachment 319751 [details]
> > Patch
> > 
> > View in context:
> > https://bugs.webkit.org/attachment.cgi?id=319751&action=review
> > 
> > > Source/WebCore/css/DOMMatrixReadOnly.cpp:99
> > > +static bool sameValueZero(double a, double b)
> > 
> > It may be in the spec, but I find the name of this very confusing, and not
> > at all memorable. Also, should it go into MathExtras.h?
> 
> I agree the name's not good. Have any ideas for a better one? I'm not a fan
> of putting things in MathExtras.h (or other shared places) that are only
> used in one place (though I admit its a bit of a chicken and the egg. If
> it's not in the shared place, how will people know about it?)
> 
> Happy to move it if we can come up with a non-terrible name.

nanEquivalentCompare() or something?
Comment 8 Radar WebKit Bug Importer 2017-09-27 12:58:42 PDT
<rdar://problem/34694412>