Re: [cc65] Interrupt handlers in C as part of the C library ?

From: Groepaz <groepaz1gmx.net>
Date: 2012-01-22 02:07:41
On Saturday 21 January 2012, Ullrich von Bassewitz wrote:
> Hi!
> 
> On Sat, Jan 21, 2012 at 02:20:49PM +0100, Oliver Schmidt wrote:
> > >> typedef unsigned (*irq_handler) (void);
> > > 
> > > Bad style, I would highly advise to use the "int".
> > 
> > If you refer to the return value than this is how Uz wanted it to be -
> > or at least how I understood him that he wanted it to be.
> 
> Using "int" in every place is
> a bad idea. I've suffered from some nasty bugs in the past that were
> caused by this "everything must be an int" rule.

especially for cc65 its a really bad idea to pass 2 bytes when 1 is enough. 
unless code size means nothing to you that is =)

-- 

http://www.hitmen-console.org    http://magicdisk.untergrund.net
http://www.pokefinder.org        http://ftp.pokefinder.org

'Just some not too serious nitpicking: The game crashes whenever I hit restore 
(and I hit it all the time, it's my hobby)' 
<tfg>

----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Sun Jan 22 02:07:22 2012

This archive was generated by hypermail 2.1.8 : 2012-01-22 02:07:25 CET