|
-----Original Message----- From: rpg400-l-bounces@midrange.com [mailto:rpg400-l-bounces@midrange.com]On Behalf Of Peter Dow Sent: Monday, February 10, 2003 10:24 PM To: RPG programming on the AS400 / iSeries Subject: Re: /FREE RPG compiler errors >I believe Gary's point was that it's readable, but to determine what a MOVE >opcode actually doing, you have to know the definitions of Factor 2 and the >Result field, but with the /free method it becomes apparent just by looking >at the EVAL statement. Hi Peter, In mine and dare I say Bjarne Stroustrup's opinion Gary is wrong on this point. One of the objectives of good program design is to abstract away as many of the underlying details of the objects of a program as possible. In C++, the action of "A = B" depends on what A and B are. All the coder knows ( and needs to know ) is that the value of B will be assigned to A. Same thing with the RPG MOVE ( should be COPY but who wants to quibble? ). When you see a MOVE stmt, you know that the value of factor 2 is being copied right justified to the result variable. >Also, you talk about removing the MOVE opcode. If you mean it's been >removed from RPG IV, that is not the case. If you mean it's been removed >from the /free syntax, it was never in it. If you mean IBM plans to remove >it from the language, I doubt it. The problem with not including MOVE in /free is that IBM did not provide the ability to write a proc version of MOVE. What is needed are data pointers in RPG, that is a pointer that also contains the attributes of the data pointed to. Or an OPDESC that actually has a complete set of operand description information. Or allow programmers to write their own BIFs. Steve
As an Amazon Associate we earn from qualifying purchases.
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.