> Thank you for the really helpful explanation!
> Now I understand the reasons but I don't have enough experience in C or the
> engine to make that possible.
> Would it be possible to support it in the first place only if the return
> type hints are already known by the engine?

If my memory is working correctly, opcache will prevent this from
working as you expect when it is enabled.

I think we want covariant return types eventually, but for now getting
invariant return types into the engine is a nice stepping stone.

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to