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

Automatic ios memory management #712

Merged
merged 6 commits into from
Feb 29, 2020

Conversation

pakko972
Copy link
Collaborator

This pull requests enable automatic memory management when possible.
The following code won't be needed anymore, GRDB takes care of if for you.

dbQueue.setupMemoryManagement(in: application)
// OR
dbPool.setupMemoryManagement(in: application)

Signed-off-by: Pakkito <pe@pierlis.com>
Signed-off-by: Pakkito <pe@pierlis.com>
groue
groue previously requested changes Feb 28, 2020
Copy link
Owner

@groue groue left a comment

Choose a reason for hiding this comment

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

Merci Pascal,

But let's not introduce any breaking change :-)

GRDB/Core/DatabasePool.swift Outdated Show resolved Hide resolved
- Deprecate setupMemoryManagement(application:)
- UIApplication is not available on watchOS, so instead of checking against `#if canImport(UIKit)` we use `#if os(iOS)`

Signed-off-by: Pakkito <pe@pierlis.com>
@groue
Copy link
Owner

groue commented Feb 29, 2020

LGTM! Thank you @pakko972, that's a much welcomed addition that will reduce soulless copy and paste 👍

@groue groue merged commit fd029ff into groue:development Feb 29, 2020
@groue
Copy link
Owner

groue commented Mar 2, 2020

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants