× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



>From the digest:

--__--__--
> From: "York, Albert" <albert.york@nissan-usa.com>
>
> I believe you're right. However, this has the be one of the
> best examples
> I've ever seen of something you can do in RPG that you shouldn't.
>

I agree with you, Albert.  Ugly as sin.  Not the worst case I've seen tho.
I keep telling myself, "one step at a time..."



>
> --__--__--
>
> From: MWalter@hanoverwire.com
>
> What did you do to deserve this?
>

Heh heh...   had the RPG experience.  This company bought a different
company several years ago.  Their package was (is?) old S/36 stuff.  OCL,
RPGII mixed with CL and RPGIII.  I wrote a VERY small RPGIV program and the
other staff went nuts.  The boss questioned whether it should be done as
nobody else could maintain it.  Sad, sad situation...   :-(


> --__--__--
> From: "Bob Cozzi \(RPGIV\)" <cozzi@rpgiv.com>
>
> David,
> I'd have to go back and look at the code that gets generated, but I
> believe the condition indicator is NOT part of the IF
> statement itself.
> That is it may transfer control to the corresponding END(IF) statement
> rather than to the else.
> Each use of an indicator in RPG III generates a compare and branch
> instruction.
> Normally, the branch jumps around the corresponding opcode.
> But since the opcode is an IF, the IF is never performed,
> hence the ELSE
> doesn't apply.
> So unless someone bothers to go read the IRP listing for this, I would
> guess on a Not 44, control branches to the END(IF) statement, not the
> ELSE statement.
>
> Bob Cozzi

I agree, Bob.  I looked throughout the RPG Programmer's Guide and couldn't
find anything about conditionally executing an IF statement.  Probably with
good reason - who in their right mind would code it that way?


To all who responded, thanks for the answers and for feeling my pain.  :-)




As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.