home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.pascal
- Path: sparky!uunet!charon.amdahl.com!amdahl!rtech!sgiblab!zaphod.mps.ohio-state.edu!malgudi.oar.net!news.uakron.edu!mcs.kent.edu!condor.mcs.kent.edu!delozier
- From: delozier@condor.mcs.kent.edu (Greg Delozier)
- Subject: Re: Help w/ THINK Pascal!
- Message-ID: <1993Jan28.034040.12533@mcs.kent.edu>
- Sender: news@mcs.kent.edu
- Nntp-Posting-Host: mcs.kent.edu
- Organization: Department of Mathematics and Computer Science, Kent State University
- References: <1993Jan27.223142.9232@news.unomaha.edu> <2677@blue.cis.pitt.edu>
- Date: Thu, 28 Jan 1993 03:40:40 GMT
- Lines: 31
-
- In article <2677@blue.cis.pitt.edu> wbdst+@pitt.edu (William B Dwinnell) writes:
- [...as an example of opening a file...]
- > Assign(infile,'TEST.DAT'); { Associates the filename with the var }
- > Reset(infile); { opens the file for reading }
-
- Well, the assign/reset pair came into popular use (so far as I know) with
- Turbo Pascal. Previous to this, on, say, UCSD Pascal, one would use:
- Reset(infile,'TEST.DAT');
- or perhaps
- Rewrite(outfile,'TEST.DAT');
-
- Why Borland added the 'assign' keyword into a language so obviously patterned
- after UCSD,etc, I don't know. (See, for instance, string handling routines...)
-
- Anyway, the point is that Apple sort of inherited the UCSD Pascal traditions
- when it started writing its own Pascal implementations, and of course, the
- THINK Pascal people follow along. Hence, THINK Pascal uses:
- Reset(infile [,title] );
- where title is an optional string, and may be omitted on an already open file
- to 'rewind' it.
-
- For the original poster of the question (the name I don't recall, sorry):
-
- Of course, this is in my THINK Pascal User Manual. If you don't have one, you
- will be wasting a lot of time figuring out what THINK Pascal can & can't do.
- It's worth the $$$ to get one by purchasing a licensed copy of the compiler.
-
- Best wishes,
-
- -greg
-
-