WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
161636
Align srcset attribute parsing with the HTML specification
https://bugs.webkit.org/show_bug.cgi?id=161636
Summary
Align srcset attribute parsing with the HTML specification
Chris Dumez
Reported
2016-09-06 12:04:19 PDT
Align srcset attribute parsing with the HTML specification: -
https://html.spec.whatwg.org/#parse-a-srcset-attribute
This is covered by:
http://w3c-test.org/html/semantics/embedded-content/the-img-element/srcset/parse-a-srcset-attribute.html
Firefox and Chrome pass all of these checks. However, WebKit fails 100 out of 236.
Attachments
Patch
(33.55 KB, patch)
2016-09-06 12:37 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Chris Dumez
Comment 1
2016-09-06 12:37:04 PDT
Created
attachment 288037
[details]
Patch
Darin Adler
Comment 2
2016-09-06 15:39:24 PDT
Comment on
attachment 288037
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=288037&action=review
> Source/WebCore/html/parser/HTMLSrcsetParser.cpp:137 > + Optional<double> density = parseValidHTMLFloatingPointNumber(descriptor);
auto?
> Source/WebCore/html/parser/HTMLSrcsetParser.cpp:144 > + Optional<int> resourceWidth = parseValidHTMLNonNegativeInteger(descriptor);
auto?
> Source/WebCore/html/parser/HTMLSrcsetParser.cpp:153 > + Optional<int> resourceHeight = parseValidHTMLNonNegativeInteger(descriptor);
auto?
Chris Dumez
Comment 3
2016-09-06 15:41:36 PDT
Comment on
attachment 288037
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=288037&action=review
>> Source/WebCore/html/parser/HTMLSrcsetParser.cpp:137 >> + Optional<double> density = parseValidHTMLFloatingPointNumber(descriptor); > > auto?
Optional<> is one of the only cases where I personally prefer not to use auto, for clarity because the !density check below becomes a bit confusing.
WebKit Commit Bot
Comment 4
2016-09-06 16:01:28 PDT
Comment on
attachment 288037
[details]
Patch Clearing flags on attachment: 288037 Committed
r205515
: <
http://trac.webkit.org/changeset/205515
>
WebKit Commit Bot
Comment 5
2016-09-06 16:01:32 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug