Re: Signedness of sizeof()
Re: Signedness of sizeof()
- Subject: Re: Signedness of sizeof()
- From: Hamish Allan <email@hidden>
- Date: Wed, 17 Mar 2010 13:15:12 +0000
On Wed, Mar 17, 2010 at 12:28 AM, Clark Cox <email@hidden> wrote:
> No, I don't believe that there is anything that you can do short of
> casting the result of sizeof to a signed type.
On Wed, Mar 17, 2010 at 1:20 AM, Andreas Grosam <email@hidden> wrote:
> I would really change his code, either using size_t for the variables a (and ensuring it doesn't get negative), or doing the explicit int cast. Mixing signed and unsigned ints in operators are potentially error prone.
Thank you both for your advice -- I'll make the changes and contact
the library author.
Best wishes,
Hamish
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden