Re: Type hinting - Request for Discussion
| From: | Alain Williams | Date: | Fri, 10 Jul 2009 14:55:23 +0000 |
| Subject: | Re: Type hinting - Request for Discussion | ||
| References: | 1 2 3 4 5 6 7 8 9 10 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-44913@lists.php.net to get a copy of this message | ||
Just to add a little fuel to this fire, should we allow the specification of return
type of functions, eg:
function int Factorial(int $num) {...}
What about things that return FALSE on error, eg fgets(), something like this:
function (string, bool) fgets(resource $handle, int $length) { ... }
I suspect that it makes things too complicated.
--
Alain Williams
Linux/GNU Consultant - Mail systems, Web sites, Networking, Programmer, IT Lecturer.
+44 (0) 787 668 0256 http://www.phcomp.co.uk/
Parliament Hill Computers Ltd. Registration Information: http://www.phcomp.co.uk/contact.php
Past chairman of UKUUG: http://www.ukuug.org/
#include <std_disclaimer.h>