News Feed
Sections




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

Dikini.net:
Poor man's macro programming in php
July 26, 2006 @ 13:27:48

vlado, thinking more about a previous post, started wondering what exactly you'd need to do to get macros working in PHP. Read on for his answers.

What is the closest we can get to that without actually changing anything in php (poor man's version? What minimal sugar does php need to make it comfy? What is the natural syntax for macros in php? I definitely don't know the answers to these questions but let's try.

He doesn't create working code, but he does make it a PHP-ish looking solution. He also suggests that while PHP doesn't have this ability (yet?), the generic function pattern can help mimic its functionality pretty closely.

0 comments voice your opinion now!
macro programming poor man generic function pattern macro programming poor man generic function pattern


blog comments powered by Disqus

Similar Posts

Jani Hartikainen's Blog: Reusable "generic" actions in Zend Framework

Metapundit.net: Partial function application in PHP

Elizabeth Naramore's Blog: The PHP Throwdown is Here!

Kevin van Zonneveld's Blog: Porting PHP to Javascript

Kevin van Zonneveld's Blog: Porting PHP to Javascript


Community Events

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


version laravel5 wordpress opinion community extension example release interview php7 laravel language framework series api podcast introduction unittest voicesoftheelephpant library

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