This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [PATCH 0/7] Fix invalid left shift of negative value.
- From: Andreas Schwab <schwab at linux-m68k dot org>
- To: DJ Delorie <dj at redhat dot com>
- Cc: vogt at linux dot vnet dot ibm dot com, binutils at sourceware dot org
- Date: Fri, 30 Oct 2015 18:45:31 +0100
- Subject: Re: [PATCH 0/7] Fix invalid left shift of negative value.
- Authentication-results: sourceware.org; auth=none
- References: <20151030143814 dot GA18070 at linux dot vnet dot ibm dot com> <20151030144201 dot GC18875 at linux dot vnet dot ibm dot com> <201510301714 dot t9UHEVS7016878 at greed dot delorie dot com> <87twp88dyz dot fsf at igel dot home> <201510301731 dot t9UHV4UI018532 at greed dot delorie dot com>
DJ Delorie <dj@redhat.com> writes:
>> ~0 is still a negative number.
>
> ~0U ?
That does the wrong thing for types wider than int.
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."