-
Notifications
You must be signed in to change notification settings - Fork 13.3k
add task-local reference counted smart pointers #6241
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
Conversation
Awesome. This is an important topic and I want to think about it a bit before r+ing, maybe get the ok from @pcwalton who has opinions on this subject. We're going to need something like this in the runtime so once it does not depend on the local heap we may end up moving it to I've been creating a lot of these container types with 🌞 |
@nikomatsakis and I came to the conclusion that the restriction of only containing An An Therefore we can have two constructors (one for |
Once #6251 lands I can remove the use of |
This looks fine to me, but I'd like someone else to sign off on it and FWIW this code could avoid using the init intrinsics by allocating with |
@brson: I think using ~ is required anyway if I'm going to allow |
To provide a reference counted pointer type with deterministic destruction once managed boxes are switched over to a garbage collector. Unlike managed boxes, these can be moved instead of just copied/cloned which is helpful for avoiding reference counts.
To provide a reference counted pointer type with deterministic destruction once managed boxes are switched over to a garbage collector. Unlike managed boxes, these can be moved instead of just copied/cloned which is helpful for avoiding reference counts. Needs #5601 to be fixed in order for safety to be provided without the current ugly workaround of making the pointers contain `Option<@()>` and `Option<@mut ()>` (which are just set to `None`). @brson: r?
update Applicability of `rc_buffer` lint from `MachineApplicable` to `Unspecified` `Unspecified` This changes `rc_buffer` from MachineApplicable to Unspecified ``` changelog: change [`rc_buffer`] to Unspecified. ``` fixes rust-lang#6241 --- changelog: change [`rc_buffer`] to Unspecified.
To provide a reference counted pointer type with deterministic
destruction once managed boxes are switched over to a garbage
collector. Unlike managed boxes, these can be moved instead of just
copied/cloned which is helpful for avoiding reference counts.
Needs #5601 to be fixed in order for safety to be provided without the current ugly workaround of making the pointers contain
Option<@()>
andOption<@mut ()>
(which are just set toNone
).@brson: r?