Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!weyrich!orville From: orville@weyrich.UUCP (Orville R. Weyrich) Newsgroups: comp.lang.fortran Subject: Re: Is this a "feature"? Message-ID: <1991May24.100709.2810@weyrich.UUCP> Date: 24 May 91 10:07:09 GMT References: <1991May23.160841.402@ac.dal.ca> Reply-To: orville@weyrich.UUCP (Orville R. Weyrich) Organization: Weyrich Computer Consulting Lines: 44 In article <1991May23.160841.402@ac.dal.ca> scrutton@ac.dal.ca writes: >I saw the super competent answers to the COMMON block initialization >question and hope someone can give me a hand with a couple of my own. > >I'd like to find out if the SAVE statement existed in FORTRAN IV (66). It was not in the IBM FORTRAN-G and FORTRAN-H compilers. It may have been an extension to some other dialects (perhaps the Burroughs stack-oriented hardware?) >I've come across some old (stylistically) code which doesn't use the >statement and depends on static allocation. Every compiler I've tried >will let you get away with referencing local variables assigned in >previous calls to that routine so it's either a standard `feature' or >part of the standard. The normal implementation allocates storage statically, in effect doing a SAVE by default. The exceptions are when overlays are done in the linkage- edit step and on certain stack-oriented Burroughs machines. > >I've also run across a DECODE statement which appears to be a precursor >to the (what's it called...) I/O using character variables as file units. DEC-10 and PDP-11 FORTRAN compilers implemented DECODE as an extension to FORTRAN-66. Other implementations may have also. It is a precursor to FORTRAN-77 I/O using character variables as I/O units (I think that WATFIV was the forst to do this, thus helping to shape the standard). >Is this yet another 66ism? VMS sure didn't like it but I thought 77 was >upward compatible with 66. The last time I looked, VAX/VMS FORTRAN did support some form of ENCODE/ DECODE, in order to maintain compatability with PDP-11 FORTRAN. This non-standard feature may have been phased out since I last worked on a VAX. -------------------------------------- ****************************** Orville R. Weyrich, Jr., Ph.D. Certified Systems Professional Internet: orville%weyrich@uunet.uu.net Weyrich Computer Consulting Voice: (602) 391-0821 POB 5782, Scottsdale, AZ 85261 Fax: (602) 391-0023 (Yes! I'm available) -------------------------------------- ******************************