Roey,
Can you please do a disassembly of this code and post the disassembly also.
Neil
> Hi,
>
> We have run across a very disturbing CodeWarrior 6 bug: there are cases
> where no code is generated for what looks like valid C source.
> Specifically, an entire if-else statement is ignored by CW6. Has anyone
> else run across anything like this? I searched through the FAQ,
> knowledge base and mailing list archives but have not seen any
> reference to similar problems.
>
> Below is an example function that has failed under several test
> configurations. If you have difficulty reproducing the problem, email
> me and I can send you a project that shows off the bug.
>
> Thanks,
>
> Roey Ben-Yoseph <[EMAIL PROTECTED]>
> Globalware Computing
>
> ++++++++++++++++++++++++++++++++++++++++
>
> static Word BuildTextLine(CharPtr dstStr, CharPtr srcStr)
> {
> Word dstStrLen;
> Word srcStrLen;
> Word copyLen;
>
> dstStrLen = StrLen(dstStr);
> srcStrLen = StrLen(srcStr);
>
> if(dstStrLen >= 37)
> return dstStrLen;
>
> //// No code is generated for this source ////
> if( (dstStrLen + srcStrLen) <= 37)
> copyLen = srcStrLen;
> else
> copyLen = (srcStrLen - ( (dstStrLen + srcStrLen) - 37));
> //// No code is generated for this source ////
>
> return copyLen;
> }
>
>
>
>
--
Neil Rhodes
Calliope Enterprises, Inc.
1328 Clock Avenue
Redlands, CA 92374
(909) 793-5995 [EMAIL PROTECTED] fax: (909) 793-2545