Path: utzoo!attcan!uunet!sco!seanf From: seanf@sco.COM (Sean Fagan) Newsgroups: comp.lang.fortran Subject: Re: Fortran vs C for computations Summary: replying again, sigh Message-ID: <1226@scolex> Date: 11 Sep 88 20:05:43 GMT References: <3169@emory.uucp> <3338@lanl.gov> Reply-To: seanf@sco.COM (Sean Fagan) Organization: The Santa Cruz Operation, Inc. Lines: 38 In article <3338@lanl.gov> jlg@lanl.gov (Jim Giles) writes: >So what? Functions called by dead code aren't really called after all. >What difference does it make if the _if_ statement or the _ifdef_ directive >is the visable syntax? The _ifdef_ was only introduced because many >compilers are _very_ bad at dead code elimination. >_OPEN_ statements which are 'system specific' are non-standard and don't >enter into this discussion. In any case, a compiler which complains of >syntax errors in an OPEN statement which appears in the middle of a dead >code sequence should be fixed. Furthermore, there are ways to provide >I/O extensions to Fortran without muching up the OPEN statement (I am just >finishing an I/O support library for Fortran on the Crays, I provide a >large number of extensions - including all the features proposed in >8x - without altering the OPEN statement syntax in any compiler-checkable >way). [I deleted mucho stuff; sorry] This is the whole point. The preprocessor (which you call unnecessary), permits me to write a program on BSD, port it to SYSV, thence to VMS, and end up with *one* program which will compile with no changes (such as, oh, for a trivial example, take GNU EMACS). I would like to see *any* FORTRAN program, doing non-trivial stuff (i.e., more than just simple I/O and number crunching), behave the same way, WITHOUT A PREPROCESSOR. Take, for example, one of the world's most perfect FORTRAN machines [my bias coming through; sorry again 8-)]: the CDC Cyber 170/760. Also take the (painfully slow) DEC VAX 8800. Write a useful program in FORTRAN on the VAX. Try to compile it on the Cyber. Oops! The compiler complained of massive syntax errors. Why? VMS allows $'s in names, long function names, etc. NOS doesn't. With a preprocessor, your problems go away (almost). I like C on Unix systems. I like FORTRAN on NOS. I wish, at times, that NOS had a preprocessor, but it doesn't. -- Sean Eric Fagan | "Joy is in the ears that hear, not in the mouth that speaks" seanf@sco.UUCP | -- Saltheart Foamfollower (S. R. Donaldson) (408) 458-1422 | Any opinions expressed are my own, not my employers'.