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

Handle anonymous classes #3399

Merged
merged 1 commit into from
Jun 27, 2024
Merged

Handle anonymous classes #3399

merged 1 commit into from
Jun 27, 2024

Conversation

AJenbo
Copy link
Collaborator

@AJenbo AJenbo commented Jun 6, 2024

Fixes #3398

Generate a name similar to the run time names for anonymous classes, when encountering a classes with no identifier.

Before this PR a class with no identifier would not be set as the current scope so it's content would instead be assigned to which ever previous scope was set (usually a method) which could lead to crashes when trying to cast it to a class.

@AJenbo AJenbo added the PHP label Jun 6, 2024
@eranif eranif merged commit 1a9c502 into eranif:master Jun 27, 2024
3 checks passed
@AJenbo AJenbo deleted the anonymous-class branch June 27, 2024 08:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: Crash on anonumous classe with traits
2 participants