[webkit-reviews] review denied: [Bug 211880] [IPC] Use templates to reduce duplicate code in Persistence::Decoder and Persistence::Encoder classes : [Attachment 399331] Patch v1
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed May 13 22:04:41 PDT 2020
Alex Christensen <achristensen at apple.com> has denied David Kilzer (:ddkilzer)
<ddkilzer at webkit.org>'s request for review:
Bug 211880: [IPC] Use templates to reduce duplicate code in
Persistence::Decoder and Persistence::Encoder classes
https://bugs.webkit.org/show_bug.cgi?id=211880
Attachment 399331: Patch v1
https://bugs.webkit.org/attachment.cgi?id=399331&action=review
--- Comment #4 from Alex Christensen <achristensen at apple.com> ---
Comment on attachment 399331
--> https://bugs.webkit.org/attachment.cgi?id=399331
Patch v1
View in context: https://bugs.webkit.org/attachment.cgi?id=399331&action=review
>> Source/WTF/wtf/persistence/PersistentEncoder.h:51
>> + static_assert(sizeof(E) <= sizeof(uint64_t), "Enum type must not be
larger than 64 bits.");
>
> Is this static_assert() still needed now that the method is a template?
This is still needed. In the decoder we should change 8 to sizeof(uint64_t).
We also can't make this change (uint64_t to std::underlying_type) because
existing persisted data has encoded enums as 64-bit values.
More information about the webkit-reviews
mailing list