[webkit-dev] SerializedScriptValue: signed vs unsigned char
Glenn Adams
glenn at skynav.com
Thu Feb 7 08:31:20 PST 2013
On Wed, Feb 6, 2013 at 5:35 PM, Alec Flett <alecflett at chromium.org> wrote:
>
> Personally outside of WebKit I tend to see more "char*" as the common
> denominator for raw bytes.
>
I've been coding in C since around 1972, and I admit that in the early
days, char was used as a synonym for byte, however, that convention has
long been dropped in favor of unsigned char. See [1] for a nice discussion,
especially the second answer.
[1]
http://stackoverflow.com/questions/653336/should-a-buffer-of-bytes-be-signed-or-unsigned-char-buffer
>
> So far Benjamin objected, and then seems to have rescinded. Glenn, do you
> depend on SerializedScriptValue's current method signatures?
>
I personally alway use unsigned char/uint8_t for raw byte strings. However,
I don't have any dependency on SerializedScriptValue.
Given Maciej and Adam's comments, you had best stay with unsigned
char/uint_8 and convert any non-conforming usage to this pattern when
needed.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20130207/5e5c78eb/attachment-0001.html>
More information about the webkit-dev
mailing list