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

[clang] Fix a crash when a variable is captured by a block nested inside a lambda #8825

Merged
merged 1 commit into from
May 31, 2024

Conversation

ahatanaka
Copy link

Eval->Value.get returns a null pointer when the variable doesn't have an initializer. Use cast_if_present instead of cast.

This fixes llvm#93625.

rdar://128482541
(cherry picked from commit e1c3e16)

Conflicts:
clang/docs/ReleaseNotes.rst

…ide a lambda (llvm#93749)

`Eval->Value.get` returns a null pointer when the variable doesn't have
an initializer. Use `cast_if_present` instead of `cast`.

This fixes llvm#93625.

rdar://128482541
(cherry picked from commit e1c3e16)

Conflicts:
	clang/docs/ReleaseNotes.rst
@ahatanaka ahatanaka merged commit c0ae354 into stable/20240408 May 31, 2024
@ahatanaka ahatanaka deleted the getinit-check-null branch May 31, 2024 00:04
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.

None yet

2 participants