POV-Ray : Newsgroups : povray.beta-test : bug with #declare order : bug with #declare order Server Time
2 Nov 2024 15:26:36 EDT (-0400)
  bug with #declare order  
From:
Date: 26 Oct 2001 05:44:58
Message: <1nbitto64ipgqujonpn6m6r7097rsol9ec@4ax.com>
platform: POV35b6 on PII233 128 MB with NT4 SP6

I hope it is not a limitation like #if inside #if

two-line script
  #declare A#declare A=0;=1;
  #warning str(A,0,0)
prints 1 and I expected it
but script
  #declare A=#declare A=0;1;
  #warning str(A,0,0)
prints 0 but I expected 1
but what is most strange when I joined both
  #declare A#declare A=0;=1;
  #warning str(A,0,0)
  #declare A=#declare A=0;1;
  #warning str(A,0,0)
it twice prints 1
but when I changed it to (replaced second A with B)
  #declare A#declare A=0;=1;
  #warning str(A,0,0)
  #declare B=#declare B=0;1;
  #warning str(B,0,0)
it prints 0 and 1

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.