home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!mcsun!uknet!cf-cm!news
- From: spxsjm@thor.cf.ac.uk (Mr S J Morris 92)
- Newsgroups: comp.lang.fortran
- Subject: Reinventing WRITE...
- Message-ID: <29011.9212161323@thor.cf.ac.uk>
- Date: 16 Dec 92 13:23:01 GMT
- Sender: news@cm.cf.ac.uk (Network News System)
- Organization: University of Wales College at Cardiff
- Lines: 36
- X-Mailer: Cardiff Computing Maths PP Mail Open News Gateway
-
-
- I want to define a subroutine which will take the same input paramters
- as a WRITE procedure; that is, I'd like to define
-
- SUBROUTINE WRITELN(A,B)
-
- in such a way that
-
- WRITELN (7,100) X,Y
- WRITELN (6,*) 'HELLO THERE'
- WRITELN (*,*) 'HE''S GETTING CLEVER NOW'
-
- all work more or less the same as the corresponding WRITE statements (by
- the way, the reason I'm doing this is to open a file, find the endfile
- record, append a new record and then close the file again, all in a
- single call - so that I can flush the output buffer in SUN Fortran). Is
- there a way of doing this, or am I being hopelessly ambitious (I've been
- doing some programming in Turbo Pascal for Windows recently, where doing
- this would be a doddle), or is there in fact another, easier way of
- flushing the buffer on a Sun (cf. the recent thread on how to do the
- same on a VAX)?
-
- Thanks in advance for any suggestions.
-
-
- --
- Steve Morris,
- Adran Ffiseg a Seryddiaeth, Coleg Prifysgol Cymru Caerdydd.
- (Physics and Astronomy Dept., UWC Cardiff)
- ***************************************************************************
- * For God so loved the world that he* Canys felly y carodd Duw y byd fel *
- * gave his only-begotten Son, that * y rhoddodd efe ei unig-anedig Fab, *
- * whosever believes in him should * fel na choller pwy bynnag a gredo *
- * not perish but have everlasting * ynddo Ef, ond caffael ohono fywyd *
- * life. (John ch.3 v.16) * tragwyddol. (Ioan p.3 ad.16) *
- ***************************************************************************
-