[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] Remove typedef for bool from eepro100.c

From: Laurent Desnogues
Subject: Re: [Qemu-devel] [PATCH] Remove typedef for bool from eepro100.c
Date: Thu, 27 Aug 2009 16:00:17 +0200

On Thu, Aug 27, 2009 at 2:45 PM, Reimar
Döffinger<address@hidden> wrote:
> 1) stdbool bool is probably 4 bytes, not just 1 like char

It's one byte on my gcc 4.4.0.

> I suggest to just get rid of bool in this file, it is only used in 5
> places, i.e. change
>>        bool bit_el = ((command & 0x8000) != 0);
> to
>>        int bit_el = command & 0x8000;

This is dangerous if you start using bit_el in integer expressions
by accident (for instance using & or |).


reply via email to

[Prev in Thread] Current Thread [Next in Thread]