Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!yale!cmcl2!lanl!jlg From: jlg@lanl.gov (Jim Giles) Newsgroups: comp.lang.fortran Subject: Re: Function calls in the middle of subroutine CALLs? -- Is it standard fortran 77 ???? Message-ID: <58237@lanl.gov> Date: 26 Jul 90 23:44:43 GMT References: <2009@key.COM> Organization: Los Alamos Natl Lab, Los Alamos, N.M. Lines: 14 From article <2009@key.COM>, by sjc@key.COM (Steve Correll): > [...] > X .GT. Y .OR. L(Z) > > where L is a logical function which defines its dummy argument. The standard > says that if X is greater than Y, then Z becomes undefined. Not very user- > friendly, but Fortran programmers have traditionally been tough as nails. Since this started as a comparison to C, let's remember that C is just as bad here. You can't predict a-priori whether the function L() will be executed in either language. In pretty much any language, it's a bad idea to have functions with side-effects in a context like this. J. Giles