Re: [cc65] Another bug... ?

Date view Thread view Subject view

From: Ullrich von Bassewitz (
Date: 2002-07-18 16:54:31


On Thu, Jul 18, 2002 at 04:05:03PM +0200, groepaz wrote:
> look at this, problem is a case value of "0x8000" (min_int) used in a
> switch statement where the switch is done by a signed int.

Ok, I've checked the standard and it says that integer promotions on the
controlling variable should be applied. This would mean that the compiler does
indeed behave incorrectly - it should convert the variable i instead of

I have to admit that I'm not happy about this. The code is unclean, and doing
a type conversion on i for each label that does not have the same type
introduces quite some overhead under the hood. But then, the standard is the
standard is the standard...:-)

Thanks for the report, I will see what I can do about it.



Ullrich von Bassewitz                        
To unsubscribe from the list send mail to with
the string "unsubscribe cc65" in the body(!) of the mail.

Date view Thread view Subject view

This archive was generated by hypermail 2.1.3 : 2002-07-18 16:55:22 CEST