POV-Ray : Newsgroups : povray.general : Different error messages for same POV-file : Re: Different error messages for same POV-file Server Time
10 Aug 2024 03:20:49 EDT (-0400)
  Re: Different error messages for same POV-file  
From: Tor Olav Kristensen
Date: 14 Mar 2000 18:09:40
Message: <38CEC5B6.C3C921B1@online.no>
Hi Vahur

Vahur Krouverk wrote:
> 
> Tor Olav Kristensen wrote:
> >
> > Hello
> >
> Hello.
> 
> Just a thought: try to add semicolons to lines, where they are
> missing...

Hmm...

I have been a little bit worried about my use of semicolons.

Earlier I have seen that too many missing semicolons can 
cause crashes of POV-Ray (on my Windows 98 machine at home, 
and if I remember right, also on my Windows NT4 machine at 
work).

Therefore I have looked through my code to make sure that I 
had put them where I thought they should be.

But your reply (thank you btw.) made me check both my code 
and the help file once again. 

Here are my (rather lengthy) findings:

When POV-Ray parses my file, I do not get any warning 
messages like this one:

warning: All #versions and #declares of float, vector, and 
color require semi-colon ';' at end.

So everything apparently looked fine, but I thought that
maybe my array declarations should have some semi-colons as 
well (even if array declarations aren't mentioned in 
messages like the one above.)

In the help file for Windows didn't have any luck finding
explicit instructions about whether I should use semi-colons
after array declarations or not.

But I found two code examples of array declarations:

The first one 

8< snip
 #declare MyArray = array[10];
 #declare MyArray[5] = pigment{White}  //all other elements must be
                     //pigments too.
8< snip

used semi-colon, and the second one

8< snip
 #declare MyArray = array[10]
 #declare MyGrid = array[4][5]
 #declare YourArray = MyArray  //this is ok
8< snip

did not.

So now I thought that I should try to insert some of them 
after my array declarations.

So I did, but now the parser started complaining about these 
semi-colons:

#declare NNi = array[3]; <----ERROR
error: object or directive expected but ; found instead.

... So now I am totally confused about semi-colons!

;(

Regards

Tor Olav

-- 
mailto:tor### [at] hotmailcom
http://www.crosswinds.net/~tok/tokrays.html


Post a reply to this message

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