Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reflection: indicate final and abstract properties in string output #17827

Closed

Conversation

DanielEScherzer
Copy link
Member

@DanielEScherzer DanielEScherzer commented Feb 16, 2025

Add "final" and "abstract" to the result of _property_string() when outputting the string representation of a ReflectionClass or ReflectionProperty instance

@DanielEScherzer
Copy link
Member Author

CC @iluuu1994 - my understanding is that final properties was added as a part of property hooks

Copy link
Member

@iluuu1994 iluuu1994 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! Indeed, this was missed in the implementation. This should also add abstract, which was added in the same PR. It should also target 8.4+.

@DanielEScherzer DanielEScherzer changed the base branch from master to PHP-8.4 February 18, 2025 02:00
@DanielEScherzer
Copy link
Member Author

Thank you! Indeed, this was missed in the implementation. This should also add abstract, which was added in the same PR. It should also target 8.4+.

Added abstract.

I didn't send this to 8.4 originally since it isn't really a bug, but retargeted.

I was planning to also work on some kind of indication of property hooks in a follow-up, should that also go to 8.4?

@iluuu1994
Copy link
Member

I would classify this as a bug. Whether your other PR should target 8.4 depends on whether it's a bug. 😄

Copy link
Member

@iluuu1994 iluuu1994 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM otherwise

Add "final" and "abstract" to the result of `_property_string()` when
outputting the string representation of a `ReflectionClass` or
`ReflectionProperty` instance
@DanielEScherzer DanielEScherzer changed the title Reflection: indicate final properties in string output Reflection: indicate final and abstract properties in string output Feb 24, 2025
@DanielEScherzer
Copy link
Member Author

Fixed whitespace and squashed the commits

@iluuu1994 iluuu1994 closed this in 81f143e Feb 25, 2025
@iluuu1994
Copy link
Member

Thank you @DanielEScherzer!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants