Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!elroy.jpl.nasa.gov!ames!skipper!altair!maine From: maine@altair.dfrf.nasa.gov (Richard Maine) Newsgroups: comp.lang.fortran Subject: Re: Fortran 90 status Message-ID: Date: 30 Apr 91 14:54:12 GMT References: <1991Apr24.202115.16119@dragon.wpd.sgi.com> <1991Apr25.235111.26282@alchemy.chem.utoronto.ca> <1991Apr26.142249.21064@convex.com> <1991Apr29.140241.1@dev8n.mdcbbs.com> Sender: news@skipper.dfrf.nasa.gov Organization: NASA Dryden, Edwards, Cal. Lines: 30 In-reply-to: campbell@dev8n.mdcbbs.com's message of 29 Apr 91 14:02:41 GMT On 29 Apr 91 14:02:41 GMT, campbell@dev8n.mdcbbs.com (Tim Campbell) said: Tim> I do have one little thing I absolutely drives me nuts about Tim> Fortran 77 and I hope it's been addressed: Prototyping! The fact Tim> that any procedure can be called with any arguments (even if Tim> they're wrong) and no errors are generated. ... Tim> Are you "in the know" on this one? Will Fortran 90 tell me if I Tim> try to pass arguments to a subroutine which doesn't match the Tim> type of arguments expected? Yep. Well, more properly the answer is "it depends." Fortran 90 will provide diagnostics for such errors if the subroutine "interface is explicit," to use the terminology of the standard. There are several ways to make sure that your interfaces are explicit; one nice one is to put all of your subroutines in modules. Note also that the Fortran 90 standard explicitly requires compilers to be able to give diagnostics for such errors. The Fortran 77 standard does not require that the compiler do anything at all useful if you have an error. If a Fortran 77 compiler fails to give an error message for blatantly illegal code, you have no recourse in the standard. You can, of course, bitch about the quality of implementation, but not about a standard violation. -- -- Richard Maine maine@altair.dfrf.nasa.gov