[PHP-DEV] Array objects & array functions

2008-01-05 Thread Amir Abiri
Hi, I was wondering if there are any plans to introduce the ability of array functions to work with "array objects". More specifically I was thinking of starting with adding an SPL interface called ArraySearchable, and modifying php_search_array in ext/standard/array.c to accept an object that

RE: [PHP-DEV] RE: Optional scalar type hinting

2008-01-03 Thread Amir Abiri
The question that pops to my mind by reading this thread is "what's wrong with the following code": function add(int $a, int $b) { return $a + $b; } add($_REQUEST['a'], $_REQUEST['b']); // Assume $_REQUEST['a'] == '1' and $_REQUEST['b'] == '2'. And the truth is that if I was forced to explic

RE: [PHP-DEV] Re: Exceptions instead of Fatal Error when calling non existent method?

2007-12-31 Thread Amir Abiri
Also, it will allow PHP applications to recover more gracefully from this sort of error. A properly designed PHP application that already has global catch blocks and some 500 error pages will have this sort of error come under that same error handling process rather then give an ugly blank page