WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
122161
[iOS] WebCore fails to build with newer versions of clang
https://bugs.webkit.org/show_bug.cgi?id=122161
Summary
[iOS] WebCore fails to build with newer versions of clang
Daniel Bates
Reported
2013-10-01 09:06:40 PDT
Make WebCore build with newer versions of clang.
Attachments
Patch
(6.11 KB, patch)
2013-10-01 09:13 PDT
,
Daniel Bates
darin
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Daniel Bates
Comment 1
2013-10-01 09:13:08 PDT
Created
attachment 213090
[details]
Patch
Darin Adler
Comment 2
2013-10-01 09:22:40 PDT
Comment on
attachment 213090
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=213090&action=review
> Source/WebCore/platform/network/mac/ResourceResponseMac.mm:97 > +static const size_t numberOfCommonHeaderFields = sizeof(commonHeaderFields) / sizeof(AtomicString*);
Would be much nicer to use the WTF_ARRAY_LENGTH macro instead and not give a name to this. The code here actually divides the size of the array by the size of a pointer to a different type!
> Source/WebCore/platform/network/mac/ResourceResponseMac.mm:135 > + for (size_t i = 0; i < numberOfCommonHeaderFields; i++) {
Would just say: for (unsigned i = 0; i < WTF_ARRAY_LENGTH(commonHeaderFields); ++i)
Daniel Bates
Comment 3
2013-10-01 09:30:32 PDT
(In reply to
comment #2
)
> (From update of
attachment 213090
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=213090&action=review
> > > Source/WebCore/platform/network/mac/ResourceResponseMac.mm:97 > > +static const size_t numberOfCommonHeaderFields = sizeof(commonHeaderFields) / sizeof(AtomicString*); > > Would be much nicer to use the WTF_ARRAY_LENGTH macro instead and not give a name to this. The code here actually divides the size of the array by the size of a pointer to a different type! >
Oops! You're right.
> > Source/WebCore/platform/network/mac/ResourceResponseMac.mm:135 > > + for (size_t i = 0; i < numberOfCommonHeaderFields; i++) { > > Would just say: > > for (unsigned i = 0; i < WTF_ARRAY_LENGTH(commonHeaderFields); ++i)
Will fix.
Daniel Bates
Comment 4
2013-10-01 09:39:07 PDT
Committed
r156715
: <
http://trac.webkit.org/changeset/156715
>
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