-
http-parser: Do not use bitfields · dc5c8781
Bitfields suck. And if you make them with non-int types, they suck in a non-standards compliant way. Like sucking sideways or something. This commit removes all bitfields in the `http_parser` struct, and replaces them with the minimal type needed to contain their values. Note that the fields in the struct have been reordered so they can be packed with 4-byte alignment. This saves both memory on the parser (because non-int bitfields get expanded to 4byte in most compilers anyway) and time (because the fields are now properly aligned and the compiler doesn't need to generate bit-level ops to access them).
Vicent Marti committed
Name |
Last commit
|
Last update |
---|---|---|
.. | ||
http-parser | Loading commit data... | |
zlib | Loading commit data... |