Re: What do we need strict scalar type hints for?
| From: | Yasuo Ohgaki | Date: | Wed, 04 Feb 2015 09:02:12 +0000 |
| Subject: | Re: What do we need strict scalar type hints for? | ||
| References: | 1 2 3 4 5 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-81786@lists.php.net to get a copy of this message | ||
Hi Dmitry,
On Wed, Feb 4, 2015 at 4:25 PM, Dmitry Stogov <dmitry@zend.com> wrote:
> The idea of that RFC was an ability to have zero-cost assert().
>
> DbC is a much more bigger feature, it is interesting, but requires
> significant work.
Type check and DbC integration would require significant work, I guess.
If you say so, it is.
How about simple in{}, out{} block? I expect it's much simpler.
Injecting in{} and out{} block code to before/after execute() something
like this.
If execute() is replaceable as before, then we may have two execute()
for production and development. There will be zero performance cost
hopefully.
Regards,
--
Yasuo Ohgaki
yohgaki@ohgaki.net