Skip to content

fix: Change ownership rules of attribute objects#870

Merged
Antonov548 merged 7 commits intomainfrom
f-866-un-preserve-2
Jul 3, 2023
Merged

fix: Change ownership rules of attribute objects#870
Antonov548 merged 7 commits intomainfrom
f-866-un-preserve-2

Conversation

@krlmlr
Copy link
Copy Markdown
Contributor

@krlmlr krlmlr commented Jul 2, 2023

Add a global preserve list to which attribute objects can be added while no corresponding R graph object exists. This list is cleared before the next call to an igraph function.

This will only leak memory if a single igraph function call initializes attributes many times without actually using them, and only before a second igraph function call is made.

The commits can be reviewed individually.

Closes #866.

@krlmlr krlmlr force-pushed the f-866-un-preserve-2 branch 3 times, most recently from c5c6a78 to 82fb03a Compare July 2, 2023 23:41
@krlmlr krlmlr force-pushed the f-866-un-preserve-2 branch from 82fb03a to c68b9be Compare July 2, 2023 23:42
@Antonov548 Antonov548 merged commit 8452f85 into main Jul 3, 2023
@Antonov548 Antonov548 deleted the f-866-un-preserve-2 branch July 3, 2023 06:29
@krlmlr
Copy link
Copy Markdown
Contributor Author

krlmlr commented Jul 3, 2023

Thanks! This was quick, we can still do a detailed review, commit by commit, after the fact.

@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Jul 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Understand attribute hacks

2 participants