On Samstag 07 März 2009, Ullrich von Bassewitz wrote: > Good morning! > > On Sat, Mar 07, 2009 at 01:38:54AM +0100, Groepaz wrote: > > i have a dumb question... a function written in assembler (which is > > called from C) that returns an unsigned char, does it have to set the Y > > register to 0 before returning? so far i assumed yes, is that true? and > > does that requirement change if the function is declared __fastcall__ ? > > If you're talking about the X register, then yes. The compiler assumes that > the default promotions are already done, so when returning chars, the X > register has to be set. This does not depend on the __fastcall__ property > of the function. > > If you're really talking about the Y register then no, it does not have to > be set on return. uh yes, i ment X (the primary register highbyte) ofcourse... it has been late :) thanks for confirming :) -- http://www.hitmen-console.org http://magicdisk.untergrund.net http://www.pokefinder.org http://ftp.pokefinder.org Wer später bremst fährt länger schnell ---------------------------------------------------------------------- To unsubscribe from the list send mail to majordomo@musoftware.de with the string "unsubscribe cc65" in the body(!) of the mail.Received on Sat Mar 7 12:33:21 2009
This archive was generated by hypermail 2.1.8 : 2009-03-07 12:33:23 CET