Re: Return Type Hinting for Methods RFC
| From: | Alain Williams | Date: | Thu, 22 Dec 2011 15:17:32 +0000 |
| Subject: | Re: Return Type Hinting for Methods RFC | ||
| References: | 1 2 3 4 5 6 7 8 9 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-57002@lists.php.net to get a copy of this message | ||
On Thu, Dec 22, 2011 at 09:59:16AM -0500, Dmitri Snytkine wrote:
> I never said to make it mandatory, only to make it available. Just like the
> type hinting of function call is optional but not mandatory, which is a big
> advantage over Java in my opinion.
> After all, if you make return type hinting mandatory, it would break 100% of
> all existing php scripts.
Agreed. I did not make myself clear enough: It should be optional/available but
with an option to make it mandatory for a module -- on a module by module basis so
that it did not affect code outside of the module.
> To clarify I am asking to make type hinting for variable declaration an
> available option.
--
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
#include <std_disclaimer.h>