From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,4ac176af9d1c15f8 X-Google-Attributes: gidfee84,public X-Google-ArrivalTime: 1994-07-27 12:40:32 PST Path: bga.com!news.sprintlink.net!hookup!yeshua.marcam.com!MathWorks.Com!europa.eng.gtefsd.com!newsxfer.itd.umich.edu!news.itd.umich.edu!86.12.med.umich.edu!user From: peyton.bland@med.umich.edu (Peyton Bland) Newsgroups: comp.unix.osf.osf1 Subject: Re: Q: Fortran statement function problem Followup-To: comp.unix.osf.osf1 Date: 27 Jul 1994 16:50:37 GMT Organization: Univ. of Mich., Dept. of Radiology Distribution: world Message-ID: References: NNTP-Posting-Host: 86.12.med.umich.edu In article , peyton.bland@med.umich.edu (Peyton Bland) wrote: > > Has anyone had problems with statement functions in Fortran? (I know, I > know, I shouldn't be using Fortran!) We are running OSF/1 v1.3 on a DEC > Alpha and using their f77 compiler. > > Anyway, a fragment of my program looks like > > else if ( line(2:end_section(line)) .eq. 'PROGRAM-HEADER' ) then > > where end_section is a statement function defined earlier; it returns an > integer*4 value. The compiler says "missing keyword" at the "t" in "then". Sorry folks - my mistake! The problem was that my source lines were occassionally longer than 72 characters. However, the system from which I was porting this uses "f77 -72 ..." to allow longer lines, and the Alpha's compiler uses "f77 -extend_source ...". I hadn't changed the makefile, and the compiler didn't complain about an invalid keyword! Oh well... Peyton -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Peyton Bland Digital Image Processing Lab Dept. of Radiology University of Michigan ----------------------------------------------------------- "We all have better moments than anybody ever knows, and so do all the others.... We are a great mystery. Each one of us is a secret, and on that basis we ought to treat each other with the deepest respect." -- Garrison Keillor =-=-=-=-=-=-=-=-=-=-=-=-=-=-=--=-=-=-=-=-=-=-=-=-=-=-=-=-=-