|
|
hi,
clipka <ano### [at] anonymousorg> wrote:
> Am 05.12.2018 um 01:24 schrieb jr:
> > ... unintended?
> >
> No, that's entirely intentional. Commas are always optional, provided
> that this doesn't lead to ambiguity.
I have the feeling I knew but then forgot. :-(
> This will declare a 3-dimensional vector. On the other hand, the
> following will declare a 2-dimensional vector:
>
> #declare Foo = <1 -2 3>;
>
> That's because POV-Ray interprets `1 -2` as the expression `1-2`, i.e.
> the single value -1.
heh, a real trap for the unwary.
while on punctuation, following your reply to ingo on brackets etc (facepalm
moment :-)) I re-read the declaring arrays section (3.3.1.10.1), and noticed in
the table titled "Additional usage examples are as follows" the use of
semicolons after the #undefs. the documentation (3.3.2.2.4) offers no
explanation.
so when I added semicolons to my recent 'queues.inc' ([*] I know it's not the
same since I'm not removing dictionary keys, just .. experimenting), I found
that of the four (near) identical uses, two throw an error while the other
two work unchanged.
the error is: Parse Error: Expected 'numeric expression', ; found instead
occurring in the get/pop macros but working in the destroys.
the respective line numbers, referring to the file posted: 41 + 102 are ok, 57 +
115 cause "trouble".
regards, jr.
[*] http://news.povray.org/web.5be1d482cfca02966427f7f90%40news.povray.org
Post a reply to this message
|
|