[ENet-discuss] Warning in encoder

Lee Salzman lsalzman at gmail.com
Sat Oct 6 00:52:40 PDT 2012


Not a bug... -x => ~x + 1, but one instruction vs. two, so..

On Fri, Oct 5, 2012 at 12:08 PM, Ruud van Gaal <ruud at racer.nl> wrote:

> Hi,
>
> While compiling ENet v1.3.5 in Visual Studio 2008, I get this warning:
>
> compress.cpp(593) : warning C4146: unary minus operator applied to
> unsigned type, result still unsigned
>
> When looking at the ENET_RANGE_CODER_ENCODE macro it indeed looks a bit
> strange, since 'encodeLow' is unsigned, but the negative of it is used in
> that macro.
>
> Any ideas whether this indeed may be a bug in some circumstances?
>
> Cheers,
> Ruud
>
> _______________________________________________
> ENet-discuss mailing list
> ENet-discuss at cubik.org
> http://lists.cubik.org/mailman/listinfo/enet-discuss
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cubik.org/pipermail/enet-discuss/attachments/20121006/d2035dc7/attachment.html>


More information about the ENet-discuss mailing list