Remove misleading XOR
Mark Wielaard
mark@klomp.org
Wed Feb 17 18:40:04 GMT 2021
Hi Érico,
On Wed, 2021-02-17 at 15:15 -0300, Érico Nogueira wrote:
> Em 17/02/2021 13:49, Mark Wielaard escreveu:
> > -#define NO_RESIZING 0u
> > -#define ALLOCATING_MEMORY 1u
> > -#define MOVING_DATA 3u
> > -#define CLEANING 2u
> > +#define NO_RESIZING 0x0
> > +#define ALLOCATING_MEMORY 0x1
> > +#define MOVING_DATA 0x3
> > +#define CLEANING 0x2
>
> Shouldn't you keep the explicit signedness of the constant? So 0x0u
> etc.
Yes, that would probably be good. I don't think it matters in this
case. But seeing we explicitly only use 2bits to hold the state it
might be more clear to be explicit about the unsignedness. I guess,
like clang, I see hex constants as just bits without thinking of them
being constant types with a specific signedness :)
Cheers,
Mark
More information about the Elfutils-devel
mailing list