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

Do not allow casts to struct types #3234

Merged
merged 1 commit into from
Apr 21, 2022
Merged

Conversation

mihaibudiu
Copy link
Contributor

Signed-off-by: Mihai Budiu [email protected]
Fixes #3233

@mihaibudiu mihaibudiu requested a review from fruffy April 20, 2022 23:52
Copy link
Collaborator

@fruffy fruffy left a comment

Choose a reason for hiding this comment

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

So is there a spec change planned for this?

@mihaibudiu
Copy link
Contributor Author

I think this is actually in line with the current spec, which only allows casts for base types.

@mihaibudiu mihaibudiu merged commit 895e4e1 into p4lang:main Apr 21, 2022
@mihaibudiu mihaibudiu deleted the issue3233 branch April 21, 2022 22:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Casting to struct is allowed? but not always?
2 participants