POV-Ray : Newsgroups : povray.general : macro limitation, why? : Re: macro limitation, why? Server Time
20 Nov 2024 10:38:39 EST (-0500)
  Re: macro limitation, why?  
From: Lutz-Peter Hooge
Date: 26 Sep 2001 13:53:09
Message: <MPG.161c34c391e7587998968c@news.povray.org>
In article <4ev### [at] michariser>, mri### [at] gmxnet says...
> #macro return1()
>         #if (1=1)
>          1
>         #end    
> #end

This is the problem I guess. It doesn't work this way, I don't know why, 
probably a bug.

Do it like this and it should work (at least in MP and 3.5):

#macro return1()
	#if(1=1)
		#local out=1;
	#else // just for the case 1 doesn't equal 1 *g*
		#local out=0; 
	#end
	out
#end

Lutz-Peter


Post a reply to this message

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