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

Pool implementation #2

Open
nickik opened this issue Dec 7, 2017 · 3 comments
Open

Pool implementation #2

nickik opened this issue Dec 7, 2017 · 3 comments

Comments

@nickik
Copy link
Member

nickik commented Dec 7, 2017

Current pool implementation is to complicated. A simple wrapper is all we need.

@gandro
Copy link
Member

gandro commented Dec 8, 2017

I think the Chunk should contain a pool ref, to ensure it does not outlive the pool (previously done using the 'pool lifetime).

@nickik
Copy link
Member Author

nickik commented Dec 8, 2017

I hope we can add this feature back in. It is more important then the automatic de-allocation.

My goal is to set up something simple that compiles so we can have some running tests for the pools. We can then implement these features one by one on top.

I can't deal with lifetime stuff on top of all the other problems I have with the Rust code.

@gandro
Copy link
Member

gandro commented Dec 8, 2017

Oh, I don't think we need (or even want) a livetime constraint on pools, but use refcouting instead. It's really not that complicated, instead of storing the raw pointer (mps_pool_t), you need to store a PoolRef.

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

No branches or pull requests

2 participants