Skip to content

Fix memory leak #62728

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 1 commit into from
Jan 13, 2023
Merged

Fix memory leak #62728

merged 1 commit into from
Jan 13, 2023

Conversation

valeriyvan
Copy link
Contributor

No description provided.

@valeriyvan valeriyvan requested a review from artemcm as a code owner December 21, 2022 15:24
@artemcm
Copy link
Contributor

artemcm commented Dec 21, 2022

Ah, thank you very much @valeriyvan.
What do you think about hoisting the code block:

if (localSubInstanceMap)
    delete subInstanceMap;

To right after we define subInstanceMap and in a SWIFT_DEFER block?

That way adding new returns to this method won't require the developer to remember to do this.

@valeriyvan
Copy link
Contributor Author

Ah, thank you very much @valeriyvan. What do you think about hoisting the code block:

if (localSubInstanceMap)
    delete subInstanceMap;

To right after we define subInstanceMap and in a SWIFT_DEFER block?

That way adding new returns to this method won't require the developer to remember to do this.

done

@artemcm
Copy link
Contributor

artemcm commented Dec 21, 2022

@swift-ci test and merge

@AnthonyLatsis AnthonyLatsis added code health compiler The Swift compiler itself bug fix labels Dec 21, 2022
@artemcm
Copy link
Contributor

artemcm commented Dec 22, 2022

@swift-ci test and merge

@artemcm
Copy link
Contributor

artemcm commented Dec 22, 2022

@swift-ci test

@valeriyvan
Copy link
Contributor Author

ping

@AnthonyLatsis
Copy link
Collaborator

AnthonyLatsis commented Jan 12, 2023

@valeriyvan Could you squash the commits and add a "DependencyScan:" or similar tag at the start of the message?

@valeriyvan valeriyvan force-pushed the ScanDependencies-leak branch from 8f86bf5 to ba1e24d Compare January 13, 2023 14:49
@valeriyvan
Copy link
Contributor Author

@valeriyvan Could you squash the commits and add a "DependencyScan:" or similar tag at the start of the message?

done

@AnthonyLatsis
Copy link
Collaborator

@swift-ci please smoke test and merge

@AnthonyLatsis
Copy link
Collaborator

Thanks!

@swift-ci swift-ci merged commit eb2c0a7 into swiftlang:main Jan 13, 2023
@valeriyvan valeriyvan deleted the ScanDependencies-leak branch January 26, 2023 02:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code health compiler The Swift compiler itself
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants