Skip to content

Commit ac42c8b

Browse files
committed
Fix reflection check
1 parent c91f4b4 commit ac42c8b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/reflection/php_reflection.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6041,7 +6041,7 @@ ZEND_METHOD(ReflectionProperty, getSettableType)
60416041
}
60426042

60436043
/* Get-only virtual property can never be written to. */
6044-
if (prop->hooks && !prop->hooks[ZEND_PROPERTY_HOOK_SET]) {
6044+
if (prop->hooks && (prop->flags & ZEND_ACC_VIRTUAL) && !prop->hooks[ZEND_PROPERTY_HOOK_SET]) {
60456045
zend_type never_type = ZEND_TYPE_INIT_CODE(IS_NEVER, 0, 0);
60466046
reflection_type_factory(never_type, return_value, 0);
60476047
return;

0 commit comments

Comments
 (0)