Make WebCore build with newer versions of clang.
Created attachment 213090 [details] Patch
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)
(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.
Committed r156715: <http://trac.webkit.org/changeset/156715>