sho@tybalt.caltech.edu.UUCP (09/02/87)
I am in the process of converting a program to use the fixed point routines. My version of LSC seems to choke on both X2Fix() and Long2Fix(). The first bug occured in a line like FixMul(X2Fix(5.0), X2Fix(5.0)); Which gave a "Pascal argument wrong size" error. After putting in a line of the form Fixed X2Fix(); I just get a link error that says X2Fix is undefined. However, Fix2X seems to be recognized. What is going on? I have an old version of the manual, so it is not much help. My guess is that the type double is not defined as an extended, and the routine which converts doubles to Fixed is called somthing else. Something I should have checked when I was at work. *sigh*. -Sho
alen@cogen.UUCP (Alen Shapiro) (09/02/87)
In article <3857@cit-vax.Caltech.Edu> sho@tybalt.caltech.edu.UUCP (Sho Kuwamoto) writes: >I am in the process of converting a program to use the fixed point >routines. My version of LSC seems to choke on both X2Fix() and >Long2Fix(). The first bug occured in a line like > > FixMul(X2Fix(5.0), X2Fix(5.0)); > >Which gave a "Pascal argument wrong size" error. After putting in a >line of the form > > Fixed X2Fix(); > >I just get a link error that says X2Fix is undefined. ***deleted*** It would seem that despite the lack of any prototype for X2Fix() in any of my <.h> files (referenced in <#include catalog.h>) LSC does NOT want you to redefine X2Fix(). X2Fix() however does not complain if it is given the address of a variable (not a constant) - these Pascal type args are call by address i.e. var arg. I have no manual page to check this with (my docs are out of date - there is a 2.01 LSC sup. I'm waiting for from Think). so try FixMul(X2Fix(&a), X2Fix(&b)); --alen the Lisa slayer (its a long story)