www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/04/12/03:08:04

From: j DOT aldrich6 AT genie DOT com
Message-Id: <199604120646.AA111701616@relay1.geis.com>
Date: Fri, 12 Apr 96 06:51:00 UTC 0000
To: djgpp AT delorie DOT com
Mime-Version: 1.0
Subject: Re: Where is fcloseall () ?

Reply to message 4369039    from RBABCOCK AT CFA. on 04/10/96 10:05PM


>: Sorry, I don't know if this has popped up before: has the function
>: fcloseall () been lost in DJGPP V2?

I think you are confusing standard Unix/GNU functions with Borland-
specific functions.  Having worked for a brief, unsatisfactory time with
both Borland C and Turbo C, I know that they have a number of
functions that don't appear in ANSI specs, like fcloseall() and flushall().
I have also heard people say that it is possible under Turbo C to use
fflush(stdin) and have it actually get rid of everything left in the i/o buffer
thru a carriage return.  This is decidedly non-ANSI behavior, as fflush()
is only supposed to work with files open for output.

IMHO, Borland's compilers in general and Turbo C in particular have a
large number of "idiot" functions that are supposed to make the language
easier for those who don't want to take the time or trouble to learn how
to manipulate files properly.  They also lack a number of very useful
functions such as ftruncate().  Writing a program that deletes records from
a data file can be a real pain when you have to literally rewrite the file
each time you delete something. :(

P.S.  If I am assuming incorrectly the origin of fcloseall(), please forgive
me this diatribe.  :)

John

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019