[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Fun-O Basic Edition Compiler
- To: address@hidden
- Subject: Re: Fun-O Basic Edition Compiler
- From: "Scott McKay" <address@hidden>
- Date: Fri, 4 Jan 2002 09:04:46 -0500 (EST)
- Organization: ATT Broadband
- References: <200112211641.LAA28762@life.ai.mit.edu> <3C276FAF.F89966B9@mediaone.net> <3C28F100.9478041B@mediaone.net> <J79W7.38357$5W5.14498010@typhoon.ne.mediaone.net> <3C2938A6.4242FE86@mediaone.net>
- Xref: traf.lcs.mit.edu comp.lang.dylan:13864
"Carl Gay" <carlgay@mediaone.net> wrote in message
news:3C2938A6.4242FE86@mediaone.net...
>
> define method tak (x :: <integer>, y :: <integer>, z :: <integer>)
> if (y >= x)
> z
> else
> tak(tak(x - 1, y, z),
> tak(y - 1, z, x),
> tak(z - 1, x, y))
> end if
> end;
>
Try adding '=> (r :: <integer>)' as the return result of 'tak'. I'll bet
that your use of the implicit return type of <object> is defeating some
of FD's optimizations.