POV-Ray : Newsgroups : povray.beta-test : semicolon not expected : Re: semicolon not expected Server Time
30 Jul 2024 04:16:47 EDT (-0400)
  Re: semicolon not expected  
From: Christopher James Huff
Date: 7 Jan 2002 17:10:53
Message: <chrishuff-99EEE5.17113807012002@netplex.aussie.org>
In article <3c39f966@news.povray.org>,
 "Rune" <run### [at] mobilixnetdk> wrote:

> It doesn't have anything to do with macros at all, as this also generates an
> error:
> 
> #declare C = #if(1) 1 #else 2 #end ;

If you wrap the conditional in parentheses, it will work fine:

#declare C = (#if(1) 1 #else 2 #end);

#macro Test2() (#if(yes) 2 #end) #end
#local F = Test2();

-- 
 -- 
Christopher James Huff <chr### [at] maccom>


Post a reply to this message

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