WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
161885
Fix post-landing review comments after
r205787
https://bugs.webkit.org/show_bug.cgi?id=161885
Summary
Fix post-landing review comments after r205787
Chris Dumez
Reported
2016-09-12 16:44:38 PDT
Fix post-landing review comments after
r205787
.
Attachments
Patch
(12.77 KB, patch)
2016-09-12 16:48 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(12.03 KB, patch)
2016-09-12 18:42 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Chris Dumez
Comment 1
2016-09-12 16:44:58 PDT
https://bugs.webkit.org/show_bug.cgi?id=161669#c18
Chris Dumez
Comment 2
2016-09-12 16:48:36 PDT
Created
attachment 288639
[details]
Patch
Darin Adler
Comment 3
2016-09-12 18:16:42 PDT
Comment on
attachment 288639
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=288639&action=review
Looks good.
> Source/WTF/wtf/text/StringBuilder.cpp:309 > +#if USE(CF)
Other classes use a separate source file for the CF stuff. But I suppose it’s too much to ask to add a StringBuilderCF.cpp just for this.
> Source/WTF/wtf/text/StringBuilder.cpp:314 > + if (auto* characters = CFStringGetCStringPtr(string, kCFStringEncodingASCII)) {
Why not kCFStringEncodingISOLatin1? It seems a little strange that this code is so different from the code in StringCF.cpp.
> Source/WTF/wtf/text/StringBuilder.h:110 > +#if USE(CF) > + WTF_EXPORT_PRIVATE void append(CFStringRef); > +#ifdef __OBJC__ > + void append(NSString *string) { append((__bridge CFStringRef)string); } > +#endif > +#endif
In the past I have often written these as separate if statements just to avoid hard-to-read nesting. #if USE(CF) WTF_EXPORT_PRIVATE void append(CFStringRef); #endif #if USE(CF) && defined(__OBJC__) void append(NSString *string) { append((__bridge CFStringRef)string); } #endif I think that’s slightly better.
> Source/WebCore/html/parser/HTMLParserIdioms.cpp:366 > - Optional<unsigned> number = parseHTMLNonNegativeInteger(StringView(numberStart, position - numberStart)); > + Optional<unsigned> number = parseHTMLNonNegativeInteger({ numberStart, static_cast<unsigned>(position - numberStart) });
Darn, that cast to unsigned we need here makes it not quite as great as I had hoped.
Chris Dumez
Comment 4
2016-09-12 18:42:11 PDT
Created
attachment 288654
[details]
Patch
WebKit Commit Bot
Comment 5
2016-09-12 19:14:56 PDT
Comment on
attachment 288654
[details]
Patch Clearing flags on attachment: 288654 Committed
r205847
: <
http://trac.webkit.org/changeset/205847
>
WebKit Commit Bot
Comment 6
2016-09-12 19:15:02 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