News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Metapundit.net:
Partial function application in PHP
February 14, 2007 @ 07:54:00

On the Metapundit.net site, there's a new (long) entry that takes a look at one of the programming styles, functional programming, and checks into its support in PHP. Unfortunately, it's mostly a swing and a miss.

I should just get this straight right off the bat: you can't really do much functional programing in PHP. Functions are not first class citizens and the equivalent of passing functions around is passing around strings or arrays and relying on convention. No really.

He goes on by illustrating the point that PHP can do this sort of thing but only up to a point. Once you start to get into anonymous functions and moving past things like the array_map function, you start to loose a foothold. The create_function function allows for a bit more flexibility, but still doesn't fulfill the requirements needed for full support.

0 comments voice your opinion now!
partial function application arraymap createfunction programming partial function application arraymap createfunction programming


blog comments powered by Disqus

Similar Posts

Rob Allen's Blog: Zend Framework URL Rewriting in IIS7

Alexey Zakhlestin's Blog: PHP+SCGI part 2: problem with eZComponents

Semaphore CI Blog: Deploying PHP Applications with Rocketeer and Docker

IBM developerWorks: Five good programming habits in PHP

php|architect: Stored Procedure Programming for MySQL5 (Part 2)


Community Events

Don't see your event here?
Let us know!


opinion api part2 project composer application yii2 language framework php7 laravel list symfony interview introduction series example community podcast conference

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework