Skip to content

[ast] Fix a memory error in Diagnostic Emission. #35673

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

Conversation

gottesmm
Copy link
Contributor

Specifically, we were storing pointers into a SmallVector. When the small vector
resized, the pointers were no longer valid resulting in memory
corruption. Was triggered by my work adding capture diagnostics.

Specifically, we were storing pointers into a SmallVector. When the small vector
resized, the pointers were no longer valid resulting in memory
corruption. Was triggered by my work adding capture diagnostics.
@gottesmm
Copy link
Contributor Author

@swift-ci test

@gottesmm
Copy link
Contributor Author

I think this is a pretty straight forward fix. I am going to merge and do post-commit.

@gottesmm gottesmm merged commit 9bbb019 into swiftlang:main Jan 31, 2021
@gottesmm gottesmm deleted the pr-ec4c368db157ffcc3b948ed3c7cfb5b5dd03117a branch January 31, 2021 21:07
Copy link
Contributor

@varungandhi-apple varungandhi-apple left a comment

Choose a reason for hiding this comment

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

LGTM.

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.

2 participants