delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/01/24/00:00:28

Message-Id: <3.0.6.32.19990124000016.008455a0@pop.netaddress.com>
X-Sender: pderbysh AT pop DOT netaddress DOT com
X-Mailer: QUALCOMM Windows Eudora Light Version 3.0.6 (32)
Date: Sun, 24 Jan 1999 00:00:16 -0500
To: djgpp AT delorie DOT com
From: Paul Derbyshire <pderbysh AT usa DOT net>
Subject: Re: Need help with c!
In-Reply-To: <clcm-19990123-0009@plethora.net>
References: <clcm-19990117-0010 AT plethora DOT net>
Mime-Version: 1.0
Reply-To: djgpp AT delorie DOT com

At 04:37 AM 1/24/99 GMT, you wrote:
>Get rid of the word static in front of FILE *fptr because that should be
>able to change as you work with the file. If it can't change it won't work
>properly.

Static? Are you sure you have the right keyword here? const FILE * would
make the pointer impossible to re-aim; and FILE *const would make it
impossible to write through it. static FILE * only means that the pointer
(4 bytes) is allocated at program launch. If it's in a function it also
means it persists between function calls. If it's in a class, it means that
it has one instance shared for the whole class rather than there being a
pointer in every instance.
-- 
   .*.  "Clouds are not spheres, mountains are not cones, coastlines are not
-()  <  circles, and bark is not smooth, nor does lightning travel in a
   `*'  straight line."    -------------------------------------------------
        -- B. Mandelbrot  |http://surf.to/pgd.net
_____________________ ____|________     Paul Derbyshire     pderbysh AT usa DOT net
Programmer & Humanist|ICQ: 10423848|

- Raw text -


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