POV-Ray : Newsgroups : povray.general : parsing problem in POVRay : parsing problem in POVRay Server Time
4 Nov 2024 21:21:48 EST (-0500)
  parsing problem in POVRay  
From: JC (Exether)
Date: 2 Sep 2003 16:02:13
Message: <3f54f745$1@news.povray.org>
I think I found a potential bug that I couldn't find in the know bugs, 
so I report here, I hope it's the right group. Here is the code :

#macro Return_Int (A)
   #if (A>0)
     A
   #else
     0
   #end
#end

#local Var1=Return_Int (5);

You don't need any light or camera, POV-Ray complains that there should 
be a ';' at line 3 after the returned 'A' which I wouldn't expect. When 
I write :

#macro Return_Int (A)
   #if (A>0)
     A;
   #else
     0;
   #end
#end

#local Var1=Return_Int (5)

It works, but I see that more like a workaround than a correct syntax.

I hope it helps improving our worshiped POV,

JC


Post a reply to this message

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