[Coco] Re: optimizing

KnudsenMJ at aol.com KnudsenMJ at aol.com
Wed Dec 10 13:58:31 EST 2003


In a message dated 12/10/03 12:46:19 AM Eastern Standard Time, 
rtaylor at bayou.com writes:

> f(somevariable=true) then
>  //      I just tested somevariable twice
>  endif;
>  
>  or how about:
>  
>  if(somevariable<>0) then
>  endif;

These are just redundant and wasteful, but how about
    while(UnsignedVar >= 0) ... ;
which gives you lots of stare-at-screen time when run?

BTW, the 6809 C compiler is buggy re 
    if(IntVar)
and must be written
    if(InVar != 0)
since the compiler tests only one byte of the 16-bit D register.

Don't know if there's an FAQ list of Microware  C compiler bugs, but this 
would be near the top of the list (or the bottom, if compiled by Letterman :-)
--Mike K.



More information about the Coco mailing list