[futurebasic] Re: [FB] [FB^3] P headers vs C headers

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : April 2000 : Group Archive : Group : All Groups

From: Derek Smith <dereksmi@...>
Date: Fri, 21 Apr 2000 12:58:41 -1000
On Fri, 21 Apr 2000, jonathan wrote:

> le 21/04/00 18:25, Pete à furbies@... a écrit :
> 
> > The C version: TOOLBOX GetDateTime (@unsigned long) `0x20B8,0x020C
> > 
> > The P version: TOOLBOX GetDateTime(VAR secs: UInt32) `0x205F,0x20B8,0x020C
> 
> I thought that the 'difference' was just preparing the stack for the
> returned value which was implicit in one but not in the other. I think that
> I must be looking at the wrong end of the cow. Again.

In this case its a MOVE instruction in hex.  If you look closely at the C
version, the parameter is defined as __A0 which let's them skimp on the
hex, but the pascal version manually moved the parameter into
A0.  Otherwise something horrible will happen.  So use the pascal
version's inline hex as the C compiler automagically adds the needed info
when it runs across the __A0.

-D