Re: PHP 5.1

From: Date: Thu, 03 Feb 2005 19:26:01 +0000
Subject: Re: PHP 5.1
References: 1 2  Groups: php.internals 
Request: Send a blank email to internals+get-14586@lists.php.net to get a copy of this message
On Feb 3, 2005, at 1:58 PM, Terje Slettebø wrote:
Hm, I'm surprised by this response from someone who's name I recognise as an active PHP contributor. The answer strikes me as either arrogant and/or ignorant (note: I'm not saying you are that, but that's how the reply comes across, given what what operator overloading is about). As I've pointed out in other postings in this thread, operator overloading is about much more than "just" "syntactic sugar". In C++, for example, it enables important things such as function objects (being able to pass an object to a function, for example, and have it behave as a function, enabling functional programming, as well). This is not possible (possibly without jumping through major hoops) in PHP.
That's because functions are not first-class objects in PHP. You can do this same thing in straight C without operator overloading. While I'm happy (for you) that you like operator overloading, the view that it is inherently evil and leads to obtuse, magical code is not relegated to us PHP luddites. These ideas have all been discussed in depth long before you appeared on the scene to decry our lack of interest in 'evolving' the language to your liking. George

« previous php.internals (#14586) next »