> It would be easy enough to code one that returns as a numeric string the > address of one of its arguments.
My recollection is that when calling assembler from Rexx you get the address of a copy of the string data, not the address of whatever internal control block represents a "variable" in Rexx. You can modify it all you want but it's a copy of the data, not "Rexx's data" and the address is meaningless once you return to Rexx. AFAIR you get one of those VM-style "PLIST" (is that the right term?) parameters: word 1 = address, word 2 = length, x'FFFFFFFFFFFFFFFF' = end of list. There is a library function to modify a Rexx variable from assembler, but it is very "sandboxed." > Reportedly MFC deprecated the similar suggestion NO complaints about MFC. Rexx is an awesome accomplishment. Too bad it is not more widely accepted, outside of the mainframe world. Charles -----Original Message----- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Paul Gilmartin Sent: Wednesday, September 05, 2012 3:16 PM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Strings (hijacked from: The IBM zEnterprise EC12 announcment) On Wed, 5 Sep 2012 18:02:51 -0400, Tony Harminc wrote: >On 5 September 2012 15:51, Charles Mills <charl...@mcn.org> wrote: >> Rexx is so "magical" there is no real reason it could not support >> Substr(a,3,1) = 'x' and actually be doing a = Substr(a,1,2) || 'x' || >> Substr(a,4) under the covers. Even, for that matter, Substr(a,3,1) = 'xyz' >> or Substr(a,3,3) = 'x' > >Right - and that's because the process is unobservable because there is >nothing like an Addr(a) that provides a reference, loosely speaking, to >a. > But consider the effects of storage() or of user-written function packages. It would be easy enough to code one that returns as a numeric string the address of one of its arguments. Reportedly MFC deprecated the similar suggestion of allowing expressions in compound symbol tails, partly because the lexical space is already so crowded (A.(2+2) is a valid function call); partly for performance reasons; and partly because of the complexity in recognizing assignment instructions it would introduce. Consider: Substr( a, F( V ), I=J+1 ) = X ... which has function calls and relational expressions on the left of an assignment. I know; other languages do it; MFC didn't believe Rexx needed to. ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN