POV-Ray : Newsgroups : povray.off-topic : Innovative open source? : Re: Innovative open source? Server Time
6 Sep 2024 07:14:54 EDT (-0400)
  Re: Innovative open source?  
From: nemesis
Date: 4 Apr 2009 01:10:00
Message: <web.49d6eb6caca2c31cd8a4ca0d0@news.povray.org>
Darren New <dne### [at] sanrrcom> wrote:
> But that's kind of the point. Why do you think that?  Saying "order
> shouldn't matter because it's a set" is begging the question.

A set in the mathematical sense has no order.  If the guy wants order, he goes
for a list.  PHP only got array, so it has to play many roles.

> Why does order matter in argument lists, if the arguments all need distinct
> names anyway? :-)

I think it has to do with pragmatism:  it's just simpler to go with a list than
a hash.

In math, you have a function over domains and you have to make sure each
argument belongs to each domain and the simplest way to notate this is to give
the order of the domains and pass the arguments to the function in that order.
Had they opted for a named argument notation, you'd not need order, but on the
other hand you'd need a lot more typing.  Programming language designers were
conscious of that and just stacking them as they come is much easier than
unwrapping hash values.

Named arguments is a thing of a hip generation used to lots of cheap computing
power and general resources.  It's not as costly anymore to be verbose when
your tools happily churn it out for you.


Post a reply to this message

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