Dear Internals,
I have changed the variance of return types to be invariant. I have
given a further example of what invariance does and does not mean in
the RFC, as there has been some confusion about it in previous
discussions.
Are there any other questions or major concerns before I put this to vote?
I don't have any at this time, except that I don't quite yet have a
working implementation after some changes to master. I expect to have
a working implementation in a couple of days at which point I intend
to move it back into voting phase.
Cheers,
Levi Morrison
Dear Internals,
I have changed the variance of return types to be invariant. I have
given a further example of what invariance does and does not mean in
the RFC, as there has been some confusion about it in previous
discussions.Are there any other questions or major concerns before I put this to vote?
I don't have any at this time, except that I don't quite yet have a
working implementation after some changes to master. I expect to have
a working implementation in a couple of days at which point I intend
to move it back into voting phase.Cheers,
Levi Morrison
My apologies; during some editing it seems I removed the RFC link:
https://wiki.php.net/rfc/returntypehinting
Hi,
I've updated the implementation and now it's even more consistent (it
shares code for return and argument type hinting).
https://github.com/php/php-src/pull/986/files
The implementation misses support for reflection.
I think, it doesn't make a lot of sense to introduce Reflection support for
return types but not for argument types.
Probably, it's better to provide a single and consistent RFC for both.
Thanks. Dmitry.
Dear Internals,
I have changed the variance of return types to be invariant. I have
given a further example of what invariance does and does not mean in
the RFC, as there has been some confusion about it in previous
discussions.Are there any other questions or major concerns before I put this to
vote?I don't have any at this time, except that I don't quite yet have a
working implementation after some changes to master. I expect to have
a working implementation in a couple of days at which point I intend
to move it back into voting phase.Cheers,
Levi Morrison
My apologies; during some editing it seems I removed the RFC link:
https://wiki.php.net/rfc/returntypehinting
The implementation misses support for reflection.
I think, it doesn't make a lot of sense to introduce Reflection support for
return types but not for argument types.
Probably, it's better to provide a single and consistent RFC for both.
There is a draft RFC for this that Sara and I have each worked on a
bit: https://wiki.php.net/rfc/reflectionparameter.typehint
yeah, I remember I saw something :)
Lets do the core work first and then decide how the Reflection should look
like.
Thanks. Dmitry.
The implementation misses support for reflection.
I think, it doesn't make a lot of sense to introduce Reflection support
for
return types but not for argument types.
Probably, it's better to provide a single and consistent RFC for both.There is a draft RFC for this that Sara and I have each worked on a
bit: https://wiki.php.net/rfc/reflectionparameter.typehint