[comp.sys.amiga] Summary of Languages supporting Random File I/O

tad@pyr.gatech.EDU (Tad K. Mannes) (01/29/88)

I posted a query for languages which support random file i/o for the Amiga.
I appears that Basic, Pascal, Modula-2 and C and any other language which
provides access to AmigaDos support random file i/o.  I received the following
replies:

--------------------------------------------------------------------------------
	I know that both Pascal and C do, and if Modula-2 is a high-level
language like I think it is (I have never used it before), then it
should have random access file I/O as well.
						-- Glenn Lewis
glewis@cit-vax.caltech.edu
--------------------------------------------------------------------------------
Randome file I/O can be done with any language that provides access to
AmigaDOS routines, which means just about everything.
David.
	Somewhat of a silly question.  The answer is yes to everything but
pascal, which is a probable yes.  
					-Matt
--------------------------------------------------------------------------------
C has what you want, and it is part of what is known as the "standard I/O"
package (which means it is completely portable).

I have a suspicition that any language above the level of Basic will provide
what you need, because ultimately they all look like C to the operating system.

In C, 'fseek' moves the file pointer to an exact byte in the file as counted
from the beginning of the file. (The file is viewed as a magtape, even if it is
on disk - fseek does a "magtape seek".)

I suspect there are synonyms for 'fseek' in the other languages you mentioned.
--------------------------------------------------------------------------------
-- 
	tad@pyr.gatech.edu	|	Tad K. Mannes
	CCOPRTM @ GITVM1	|	Office of Computing Services
				|	Georgia Institute of Technology