Skip to content

Forbid a-vis on unilateral virtual prop #15698

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

Closed

Conversation

iluuu1994
Copy link
Member

The get-only case is obvious, there is no set operation so specifying its visibility is senseless. The set-only case is also questionable, since there is no operation other than set, so changing the visibility of the entire property is preferable.

This change was forgotten during the implementation.

The get-only case is obvious, there is no set operation so specifying its
visibility is senseless. The set-only case is also questionable, since there is
no operation other than set, so changing the visibility of the entire property
is preferable.
@bwoebi
Copy link
Member

bwoebi commented Sep 2, 2024

"Unilateral virtual property"? Is this the wording for "Virtual property with only a single hook"?
I think it's better to keep the language in errors simple.

@iluuu1994
Copy link
Member Author

What would you suggest?

@bwoebi
Copy link
Member

bwoebi commented Sep 2, 2024

Virtual property Foo::$bar with only a single hook must not specify asymmetric visibility

@iluuu1994
Copy link
Member Author

Simplified here: 7f0d257

@bwoebi
Copy link
Member

bwoebi commented Sep 3, 2024

@iluuu1994 Looks good, thanks!

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