POV-Ray : Newsgroups : povray.beta-test : Regarding ^ operator and docs Server Time
29 Jul 2024 08:22:03 EDT (-0400)
  Regarding ^ operator and docs (Message 1 to 8 of 8)  
From: Slime
Subject: Regarding ^ operator and docs
Date: 3 Jun 2002 02:56:30
Message: <3cfb131e@news.povray.org>
We had a discussion about this earlier, but it's so old that I wanted to
post this in a new thread so it wouldn't be overlooked; I hope that's ok.

We talked about precedence issues with the ^ operator. I accept whatever the
POV-Ray team chooses to do with that issue (i assume they'll leave it as
is); however, I was just looking in "6.1.3.3  Float Operators" and noticed
that it's not in there anywhere. There's a whole paragraph in there about
how POV-Ray treats some operator precedences differently than most other
languages do.

Anyway, I think it would be a good idea to add the ^ operator to this
section of the docs, and at the same time give a quick explanation of the
reason for its lower precedence than the unary - operator, maybe also
mentioning the unexpected behavior I ran across.

 - Slime
[ http://www.slimeland.com/ ]


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: Regarding ^ operator and docs
Date: 3 Jun 2002 03:31:45
Message: <3cfb1b61$1@news.povray.org>
In article <3cfb131e@news.povray.org> , "Slime" <slm### [at] slimelandcom> wrote:

> We had a discussion about this earlier, but it's so old that I wanted to
> post this in a new thread so it wouldn't be overlooked; I hope that's ok.
>
> We talked about precedence issues with the ^ operator. I accept whatever the
> POV-Ray team chooses to do with that issue (i assume they'll leave it as
> is); however, I was just looking in "6.1.3.3  Float Operators" and noticed
> that it's not in there anywhere. There's a whole paragraph in there about
> how POV-Ray treats some operator precedences differently than most other
> languages do.
>
> Anyway, I think it would be a good idea to add the ^ operator to this
> section of the docs, and at the same time give a quick explanation of the
> reason for its lower precedence than the unary - operator, maybe also
> mentioning the unexpected behavior I ran across.

This operator has been removed in RC 6.

    Thorsten

____________________________________________________
Thorsten Froehlich
e-mail: mac### [at] povrayorg

I am a member of the POV-Ray Team.
Visit POV-Ray on the web: http://mac.povray.org


Post a reply to this message

From: Felix Wiemann
Subject: Re: Regarding ^ operator and docs
Date: 3 Jun 2002 08:35:27
Message: <3cfb628f@news.povray.org>
Thorsten Froehlich wrote:
> This operator has been removed in RC 6.

Why?
-- 
Felix Wiemann


Post a reply to this message

From: Tim Nikias
Subject: Re: Regarding ^ operator and docs
Date: 3 Jun 2002 10:10:27
Message: <3CFB78C1.F4EF5D1B@gmx.de>
Felix Wiemann schrieb:

> Thorsten Froehlich wrote:
> > This operator has been removed in RC 6.
>
> Why?
> --
> Felix Wiemann

Probably because its unexpected use and because you can do
similiar with pow(X,Y)... Which would be expected behaviour...

Just an educated guess though...

--
Tim Nikias
Homepage: http://www.digitaltwilight.de/no_lights/index.html
Email: Tim### [at] gmxde


Post a reply to this message

From: Ken
Subject: Re: Regarding ^ operator and docs
Date: 3 Jun 2002 10:35:05
Message: <3CFB7F6F.AF84FFE5@pacbell.net>
Tim Nikias wrote:
> 
> Felix Wiemann schrieb:
> 
> > Thorsten Froehlich wrote:
> > > This operator has been removed in RC 6.
> >
> > Why?
> > --
> > Felix Wiemann
> 
> Probably because its unexpected use and because you can do
> similiar with pow(X,Y)... Which would be expected behaviour...

That pretty much sums it up. It boils down to design consistency and
the desire to minimize endless debate on the order of operator precedence.

-- 
Ken Tyler


Post a reply to this message

From: Tim Nikias
Subject: Re: Regarding ^ operator and docs
Date: 3 Jun 2002 10:39:38
Message: <3CFB7F99.644438BE@gmx.de>
> ...
> That pretty much sums it up. It boils down to design consistency and
> the desire to minimize endless debate on the order of operator precedence.

Woohoo! I'm a genius! ;)


--
Tim Nikias
Homepage: http://www.digitaltwilight.de/no_lights/index.html
Email: Tim### [at] gmxde


Post a reply to this message

From:
Subject: Re: Regarding ^ operator and docs
Date: 3 Jun 2002 11:09:18
Message: <5t0nfuke07hv366kq7p0tl01noqjo1ua0q@4ax.com>
On Mon, 03 Jun 2002 07:38:39 -0700, Ken <tyl### [at] pacbellnet> wrote:
> That pretty much sums it up. It boils down to design consistency and
> the desire to minimize endless debate on the order of operator precedence.

Moreover I have noticed problems (probably not reported yet) that ^ operator
caused crash when used in something like G^.5 with G=-0.0. The same expression
with abs(G)^.5 or sqrt(G) worked fine or returned error.

ABX


Post a reply to this message

From: Slime
Subject: Re: Regarding ^ operator and docs
Date: 3 Jun 2002 14:43:39
Message: <3cfbb8db$1@news.povray.org>
> This operator has been removed in RC 6.


Wow. Well, never mind then. =) Too bad, I liked the ease of use it provided.

Will it still work inside functions? (As a function operator, not an SDL
one?)

 - Slime
[ http://www.slimeland.com/ ]


Post a reply to this message

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