× 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.



Now Now! No call for bad language!!

Actually I agree greatly - we also have old code with lots of CAS* and maybe CAB*!

Vern

On 4/13/2016 3:15 PM, Mark Murphy/STAR BASE Consulting Inc. wrote:
Wow, convert GOTO operations? I bet that can get dicey!

Mark Murphy
STAR BASE Consulting, Inc.
mmurphy@xxxxxxxxxxxxxxx


-----Charles Wilt <charles.wilt@xxxxxxxxx> wrote: -----
To: "Rational Developer for IBM i / Websphere Development Studio Client for System i & iSeries" <wdsci-l@xxxxxxxxxxxx>
From: Charles Wilt <charles.wilt@xxxxxxxxx>
Date: 04/13/2016 11:01AM
Subject: Re: [WDSCI-L] Conversion to free-form


ADD, Z-ADD, and MOVE can be converted...

However, it's not a simple conversion. You have to look at the types and
sizes of the fields involved.

IBM, rightly or wrongly, has left the advanced conversion to it's partners.

I've used and highly recommend Linoma's tool, iirc it's considerably
cheaper than the alternatives.

When using it for conversions, you have the following options:
Target IBM i release . . . . . . *CURRENT *CURRENT, VxRx
Format of specifications . . . . *FREE2 *FREE, *FREE2, *FIXED
Examine field attributes . . . . *YES *NO, *YES
Expand copy members . . . . . . *NO *NO, *YES
Redefine data structures . . . . *YES *NO, *YES
Redefine *LIKE DEFN fields . . . *YES *NO, *YES
Redefine calc. defined fields . *YES *NO, *YES
Convert left hand indicators . . *YES *NO, *YES
Convert opcodes to BIFs . . . . *YES *NO, *YES
Convert key lists (KLIST) . . . *YES *NO, *YES, *YES2
Insert file I/O BIFs . . . . . . *YES *NO, *YES, *YES2
Convert ADDs/SUBs to EVALs . . . *YES *NO, *YES, *YES2
Convert Z-ADDs/Z-SUBs to EVALs *YES *NO, *YES, *YES2
Convert MULTs to EVALs . . . . . *YES *NO, *YES, *YES2
Convert DIVs to EVALs . . . . . *YES *NO, *YES, *YES2
Convert MOVE(L)s having *BLANK *CLEAR *NO, *EVAL, *CLEAR
Convert MOVE(L)s having *ZERO . *CLEAR *NO, *EVAL, *CLEAR
Convert MOVEs having data . . . *EVAL *NO, *EVAL
Convert MOVELs having data . . . *EVAL *NO, *EVAL
Convert MOVEA operations . . . . *YES *NO, *YES
Convert CASxx operations . . . . *YES *NO, *YES
Convert CAT operations . . . . . *YES *NO, *YES, *YES2
Convert DOs to FORs . . . . . . *YES *NO, *YES
Convert LOOKUP operations . . . *YES *NO, *YES
Convert SCAN operations . . . . *YES *NO, *YES

Convert *ENTRY PLIST . . . . . . *YES *NO, *YES, *YES2

Convert Subroutines to Procs . . *NO *NO, *YES

Convert CALLs and CALLBs . . . . *YES *NO, *YES, *YES2

Convert GOTO operations . . . . *YES *NO, *YES

Compress expressions . . . . . . *YES *NO, *YES

Highlight comments . . . . . . . *NO *NO, *YES

Fixed-form comment designator . *SLASHES *LEAVE, *ASTERISK,
*SLASHES
Comment specification types . . *REMOVE *LEAVE, *REMOVE

Comment designator on blanks . . *LEAVE *LEAVE, *REMOVE

Case for specification types . . *LOWER *LEAVE, *LOWER, *UPPER

Case for unchanged logic . . . . *LOWER *LEAVE, *LOWER, *UPPER...

Case for changed and new logic *LOWER *LOWER, *UPPER, *MIXED...

Case for in-line comments . . . *LEAVE *LEAVE, *LOWER, *UPPER

Case for right-hand comments . . *LEAVE *LEAVE, *LOWER, *UPPER

Free-form indent nested logic . *LEAVE *LEAVE, *INDENT0,
*INDENT1...
Document nested logic . . . . . *NO *NO, *YES
Clean RPG source . . . . . . . . *NO *NO, *YES
Source date on converted lines *KEEP *KEEP, *TODAY, *ZEROS


The key option is "Examine Field Attributes", that must be *YES in order
for ADD/MOVE/ect conversion to be used.

Charles


On Wed, Apr 13, 2016 at 10:50 AM, Duane Scott <dscott@xxxxxxxxxxx> wrote:

I've heard that argument before, and I'm not sure I can come up with
examples that couldn't be configured. I accept that there are non-simple
MOVEs, but not sure that they couldn't be transformed into an eval
statement, even MOVES from numeric to string fields or versa-vice.

Maybe I should check the boards before raising this issue. Sorry. Any
question as to which list it should be in?

Duane

-----Original Message-----
From: WDSCI-L [mailto:wdsci-l-bounces@xxxxxxxxxxxx] On Behalf Of Vernon
Hamberg
Sent: Wednesday, April 13, 2016 9:32 AM
To: Rational Developer for IBM i / Websphere Development Studio Client for
System i & iSeries <wdsci-l@xxxxxxxxxxxx>
Subject: Re: [WDSCI-L] Block printing lines in LPEX - Last Change Date
included

Hi Duane

As to why the ADD, Z-ADD, MOVE are not converted? For one thing, those do
not have a direct equivalent opcode in free-form - no MOVE, for example. It
does seem that Z-ADD could easily be changed to an assignment - MOVE
operations are so varied in their use and result that changing to
assignments is difficult in the extreme.

HTH
Vern

On 4/13/2016 6:47 AM, Duane Scott wrote:
Agreed. Although, I wish more shops would agree to allow more recent
coding techniques like removal of the EVAL opcode. Even that would be an
improvement.
Speaking of which, does anybody understand why the IBM free form
converter cannot convert ADD, Z-ADD, or MOVE? I probably missed the
original explanation, or have since then forgot it. (OOPS! Didn't mean to
change the thread.)
Duane

-----Original Message-----
From: WDSCI-L [mailto:wdsci-l-bounces@xxxxxxxxxxxx] On Behalf Of Mark
Murphy/STAR BASE Consulting Inc.
Sent: Wednesday, April 13, 2016 7:17 AM
To: Rational Developer for IBM i / Websphere Development Studio Client
for System i & iSeries <wdsci-l@xxxxxxxxxxxx>
Subject: Re: [WDSCI-L] Block printing lines in LPEX - Last Change Date
included
Then use subroutines instead of procedures. There have long been ways to
logically segment programs. We haven't "had" to program in a giant
monolithic block style since RPG II.
Mark Murphy
STAR BASE Consulting, Inc.
mmurphy@xxxxxxxxxxxxxxx


-----Duane Scott <dscott@xxxxxxxxxxx> wrote: -----
To: "Rational Developer for IBM i / Websphere Development Studio Client
for System i & iSeries" <wdsci-l@xxxxxxxxxxxx>
From: Duane Scott <dscott@xxxxxxxxxxx>
Date: 04/12/2016 02:15PM
Subject: Re: [WDSCI-L] Block printing lines in LPEX - Last Change Date
included

Not easy to do when procedures are not common practice in the shop you
work in.
I agree though, that if it's an option, take advantage of it as much as
possible.
Duane


-----Original Message-----
From: WDSCI-L [mailto:wdsci-l-bounces@xxxxxxxxxxxx] On Behalf Of Mark
Murphy/STAR BASE Consulting Inc.
Sent: Tuesday, April 12, 2016 2:11 PM
To: Rational Developer for IBM i / Websphere Development Studio Client
for System i & iSeries <wdsci-l@xxxxxxxxxxxx>
Subject: Re: [WDSCI-L] Block printing lines in LPEX - Last Change Date
included
-----John Yeung <gallium.arsenide@xxxxxxxxx> wrote: -----

...

Which seems nice. But that area in the margin looks pretty small; what
happens when you are in that 100-line, 12-deep control block?

...
Don't do that, break it into sub procedures with appropriate names.
Deeply nested code is so much easier to mess up because you have to keep
the whole thing in your head all at once.
--
This is the Rational Developer for IBM i / Websphere Development Studio
Client for System i & iSeries (WDSCI-L) mailing list To post a message
email: WDSCI-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list
options,
visit: http://lists.midrange.com/mailman/listinfo/wdsci-l
or email: WDSCI-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives at
http://archive.midrange.com/wdsci-l.
________________________________
________________________________
CONFIDENTIALITY NOTICE: This electronic message transmission is
intended only for the person or entity to which it is addressed and may
contain information that is privileged, confidential or otherwise protected
from disclosure. If you have received this transmission, but are not the
intended recipient, you are hereby notified that any disclosure, copying,
distribution or use of the contents of this information is strictly
prohibited. If you have received this e-mail in error, please contact NALC
Health Benefit Plan at 703-729-4677 and delete and destroy the original
message and all copies.



--
This is the Rational Developer for IBM i / Websphere Development Studio
Client for System i & iSeries (WDSCI-L) mailing list
To post a message email: WDSCI-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/wdsci-l
or email: WDSCI-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/wdsci-l.
--
This is the Rational Developer for IBM i / Websphere Development Studio
Client for System i & iSeries (WDSCI-L) mailing list
To post a message email: WDSCI-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/wdsci-l
or email: WDSCI-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/wdsci-l.

________________________________
________________________________
CONFIDENTIALITY NOTICE: This electronic message transmission is
intended only for the person or entity to which it is addressed and may
contain information that is privileged, confidential or otherwise protected
from disclosure. If you have received this transmission, but are not the
intended recipient, you are hereby notified that any disclosure, copying,
distribution or use of the contents of this information is strictly
prohibited. If you have received this e-mail in error, please contact NALC
Health Benefit Plan at 703-729-4677 and delete and destroy the original
message and all copies.



--
This is the Rational Developer for IBM i / Websphere Development Studio
Client for System i & iSeries (WDSCI-L) mailing list
To post a message email: WDSCI-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/wdsci-l
or email: WDSCI-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/wdsci-l.

________________________________
________________________________
CONFIDENTIALITY NOTICE: This electronic message transmission is intended
only for the person or entity to which it is addressed and may contain
information that is privileged, confidential or otherwise protected from
disclosure. If you have received this transmission, but are not the
intended recipient, you are hereby notified that any disclosure, copying,
distribution or use of the contents of this information is strictly
prohibited. If you have received this e-mail in error, please contact NALC
Health Benefit Plan at 703-729-4677 and delete and destroy the original
message and all copies.




--
This is the Rational Developer for IBM i / Websphere Development Studio
Client for System i & iSeries (WDSCI-L) mailing list
To post a message email: WDSCI-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/wdsci-l
or email: WDSCI-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/wdsci-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

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.