Commit dca2c720112 for php.net
commit dca2c720112041158f5a199c54d44750c59eeee8
Author: Daniel Scherzer <daniel.e.scherzer@gmail.com>
Date: Thu Jul 2 13:49:54 2026 -0700
Fix inline documentation of tentative return methods
Both `ReflectionFunctionAbstract::hasTentativeReturnType()` and
`ReflectionFunctionAbstract::getTentativeReturnType()` were documented as
checking or retrieving the "return type" of a function rather than the
"tentative return type". The two are different; update the documentation
accordingly.
diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c
index 3abd95731ca..7a24f084045 100644
--- a/ext/reflection/php_reflection.c
+++ b/ext/reflection/php_reflection.c
@@ -3672,7 +3672,7 @@ ZEND_METHOD(ReflectionFunctionAbstract, getReturnType)
}
/* }}} */
-/* {{{ Return whether the function has a return type */
+/* {{{ Return whether the function has a tentative return type */
ZEND_METHOD(ReflectionFunctionAbstract, hasTentativeReturnType)
{
reflection_object *intern;
@@ -3686,7 +3686,7 @@ ZEND_METHOD(ReflectionFunctionAbstract, hasTentativeReturnType)
}
/* }}} */
-/* {{{ Returns the return type associated with the function */
+/* {{{ Returns the tentative return type associated with the function */
ZEND_METHOD(ReflectionFunctionAbstract, getTentativeReturnType)
{
reflection_object *intern;