Mail Archives: djgpp/1997/07/08/23:35:08
Art S. Kagel (kagel AT ns1 DOT bloomberg DOT com) wrote:
: On 4 Jul 1997, George Foot wrote:
: > In C you are not allowed to define variables within a block; your
: > definition of `bmh' must come before any code in the block, i.e. before
: > the fopen call. C++ does allow you to define variables almost anywhere
: > though.
: Wrong! ANSI C does indeed allow one to define variables at the beginning
: of any block! C++ further adds the ability to define variables anywhere
: within a block. Please do not post mis-information.
Sorry, what I wrote was unclear; I meant of course that any definitions
must come at the start of the block, before any code in that block. My use
of `within' was erroneous.
--
George Foot <mert0407 AT sable DOT ox DOT ac DOT uk>
Merton College, Oxford
- Raw text -