POV-Ray : Newsgroups : povray.beta-test : [doc] concat with one parameter : Re: [doc] concat with one parameter Server Time
29 Jul 2024 10:22:11 EDT (-0400)
  Re: [doc] concat with one parameter  
From: Felix Wiemann
Date: 22 May 2002 07:53:39
Message: <3ceb86c2@news.povray.org>
Christopher James Huff wrote:
> In that case, either the macro is written wrong or you are using it
> wrong. The concat() function is for concatenating strings, not making
> temporary copies. I don't see any reason to document that use, it is
> basically a hack and should be discouraged because it leads to code that
> appears to do something other than what it really does.

Where's the problem with concat? It works fine. Aren't POVers (and computer 
users in general) known for using a function for something totally 
different than it was designed for? And I don't see any possibility that's 
as short as concat.

> If you don't want to declare a temporary variable, a macro is a better
                                                                  ^^^^^^
Why?

> solution than misusing the concat() function. Something like:
> 
> #macro clonestring(String)
>     #local tmpString = String
>     tmpString
> #end

Is much longer. So not better but worse.
-- 
Felix Wiemann


Post a reply to this message

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