Path: utzoo!utgpu!watserv1!watmath!att!news.cs.indiana.edu!samsung!think.com!mintaka!mit-eddie!uw-beaver!ubc-cs!unixg.ubc.ca!cheddar.ucs.ubc.ca!buckland From: buckland@cheddar.ucs.ubc.ca (Tony Buckland) Newsgroups: comp.lang.fortran Subject: Re: I/O Message-ID: <1991Jan25.172533.5985@unixg.ubc.ca> Date: 25 Jan 91 17:25:33 GMT References: <11498@helios.TAMU.EDU> Sender: news@unixg.ubc.ca (Usenet News Maintenance) Organization: Computing Services, University of British Columbia Lines: 20 In article <11498@helios.TAMU.EDU> mkh6317@rigel.tamu.edu writes: >Ok, ok. Uncle. Since I don't have a copy of the "standard" I >will have to take your word that "equivalencing a character >variable to a non-character variable" is a violation of the >standard. Now tell me why. I assume you mean ``why was the standard made that way?" Depending on your point of view: (1) to make life miserable for everybody who had clever ways of manipulating character data in, or as though it were, variables of other types; (2) to achieve portability between systems which represent either character data or other types of data in different ways. What you are *not* supposed to do, for instance, is equivalence a four-character array to a fullword integer variable, set it to zero, and then detect digits in your input by feeding one character at a time into the right-hand byte and seeing if the integer is over 239 (if that seems incomprehensible, it's because the example is based on IBM 370 machines using EBCDIC coding, and proves the wisdom of (2)).