Skip to content

[clang][Interp] Only diagnose null field access in constant contexts #69223

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

Merged
merged 4 commits into from
Oct 26, 2023

Conversation

tbaederr
Copy link
Contributor

Looks like this should work as long as we don't dereference the value.

Note: This is a change from my local branch where I introduce integral pointers. One thing I changed is that null pointers are integral pointers and not block pointers, but in this version they are still block pointers so we have to be careful about Pointee being null.

@llvmbot llvmbot added clang Clang issues not falling into any other category clang:frontend Language frontend issues, e.g. anything involving "Sema" labels Oct 16, 2023
@tbaederr tbaederr changed the title Null field access [clang][Interp] Only diagnose null field access in constant contexts Oct 16, 2023
@tbaederr
Copy link
Contributor Author

Ping

Copy link
Collaborator

@AaronBallman AaronBallman left a comment

Choose a reason for hiding this comment

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

LGTM

@tbaederr tbaederr merged commit ba11d31 into llvm:main Oct 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clang:frontend Language frontend issues, e.g. anything involving "Sema" clang Clang issues not falling into any other category
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants