|
![](/i/fill.gif) |
On Mon, 7 Jan 2002 14:23:57 -0000, "Gleb" <gk1### [at] soton ac uk> wrote:
> The difference is not only the order of lines, but in the last case "F" in
> known as function name
I know, I pointed order to underline what changed.
> in current block, so POV is correct, reporting an error..
not for me
F listed in declaration of macro is valid name _only_ in local namespace of this
macro so according to "redeclaration of functions is not allowed" it is formal
as long as it will not be declared as function.
> If we put " #local F=" inside e.g. a macro block, like below, it works OK
yes, I pointed it in this thread
ABX
Post a reply to this message
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
Thorsten Froehlich wrote:
>
> Skiba <abx### [at] babilon org> wrote:
>
> > This is parsed ok:
> >
> > #macro P(F) #end
> > #local F=function{x}
> >
> > and this not:
> >
> > #local F=function{x}
> > #macro P(F) #end
>
> Ah, now I see. I missed that it wasn't a macro call. I am not sure what it
> is then.
It is just one function declaration and one
macro declaration.
- And the macro's parameter just happens to
have the same name as the function.
I think it should be valid code to write.
Just as this is allowed:
#declare S = sphere { <0, 0, 0>, 1 }
#macro AnyMacro(S)
(2*S)
#end // AnyMacro
#declare A = AnyMacro(4);
Tor Olav
Post a reply to this message
|
![](/i/fill.gif) |