POV-Ray : Newsgroups : povray.beta-test : Problem with #read : Re: Problem with #read Server Time
30 Jul 2024 06:19:38 EDT (-0400)
  Re: Problem with #read  
From:
Date: 3 Jan 2002 09:59:08
Message: <v0s83u42e3mqgn9eljrdba4i9iocoiepcp@4ax.com>
On Thu, 03 Jan 2002 15:36:59 +0100, Christian Walther <cwa### [at] gmxch> wrote:

> It seems that "defined" and "initialized" is not the same thing, and you
> just found a way to make an identifier that is defined but not initialized.
> From the fact that there's a special parse error message for that, it seems
> that the possible existence of uninitialized identifiers was foreseen by the
> programmers, so it wouldn't be a bug.

IMO there is some kind of bug. When you read ten variables from file but there
is nine in file then after ninth reading file handle is udefined (according to
6.2.3.3). So you can simple check EOF. But when you open empty file for reading
then handle should be undefined at begining or some warning/error could be
generated.

ABX
--
#declare _=function(a,b,x){((a^2)+(b^2))^.5-x}#default {pigment{color rgb 1}}
union{plane{y,-3}plane{-x,-3}finish{reflection 1 ambient 0}}isosurface{ //ABX
function{_(x-2,y,1)&_((x+y)*.7,z,.1)&_((x+y+2)*.7,z,.1)&_(x/2+y*.8+1.5,z,.1)}
contained_by{box{<0,-3,-.1>,<3,0,.1>}}translate z*15finish{ambient 1}}//POV35


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.