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

impl Rc::new_cyclic #75994

Merged
merged 3 commits into from
Sep 5, 2020
Merged

impl Rc::new_cyclic #75994

merged 3 commits into from
Sep 5, 2020

Conversation

mental32
Copy link
Contributor

References #75861

r? @Dylan-DPC

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Aug 27, 2020
@Dylan-DPC-zz
Copy link

r? @KodrAus

Co-authored-by: Andrew Hickman <andrew.hickman1@sky.com>
Copy link
Contributor

@KodrAus KodrAus left a comment

Choose a reason for hiding this comment

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

Thanks for working on this @mental32!

This follows the same dance as Arc::new_cyclic, which carefully avoids creating references to uninitialized data. Would you like to pull in some of the comments from Arc::new_cyclic into this Rc::new_cyclic function too so visitors can follow what's going on?

library/alloc/src/rc.rs Outdated Show resolved Hide resolved
@mental32
Copy link
Contributor Author

mental32 commented Sep 1, 2020

@KodrAus I've mad the suggested changes, feel free to review again :)

Copy link
Contributor

@KodrAus KodrAus left a comment

Choose a reason for hiding this comment

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

Thanks @mental32!

This looks good to me

@KodrAus
Copy link
Contributor

KodrAus commented Sep 4, 2020

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Sep 4, 2020

📌 Commit 0f301e8 has been approved by KodrAus

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Sep 4, 2020
matklad added a commit to matklad/rust that referenced this pull request Sep 4, 2020
matklad added a commit to matklad/rust that referenced this pull request Sep 4, 2020
matklad added a commit to matklad/rust that referenced this pull request Sep 4, 2020
matklad added a commit to matklad/rust that referenced this pull request Sep 4, 2020
matklad added a commit to matklad/rust that referenced this pull request Sep 4, 2020
Dylan-DPC-zz pushed a commit to Dylan-DPC-zz/rust that referenced this pull request Sep 4, 2020
Dylan-DPC-zz pushed a commit to Dylan-DPC-zz/rust that referenced this pull request Sep 4, 2020
Dylan-DPC-zz pushed a commit to Dylan-DPC-zz/rust that referenced this pull request Sep 5, 2020
bors added a commit to rust-lang-ci/rust that referenced this pull request Sep 5, 2020
Rollup of 11 pull requests

Successful merges:

 - rust-lang#75695 (Add a regression test for issue-72793)
 - rust-lang#75741 (Refactor byteorder to std in rustc_middle)
 - rust-lang#75954 (Unstable Book: add links to tracking issues for FFI features)
 - rust-lang#75994 (`impl Rc::new_cyclic`)
 - rust-lang#76060 (Link vec doc to & reference)
 - rust-lang#76078 (Remove disambiguators from intra doc link text)
 - rust-lang#76082 (Fix intra-doc links on pub re-exports)
 - rust-lang#76254 (Fold length constant in Rvalue::Repeat)
 - rust-lang#76258 (x.py check checks tests/examples/benches)
 - rust-lang#76263 (inliner: Check for codegen fn attributes compatibility)
 - rust-lang#76285 (Move jointness censoring to proc_macro)

Failed merges:

r? @ghost
@bors bors merged commit 4bd3f26 into rust-lang:master Sep 5, 2020
@rustbot rustbot added this to the 1.48.0 milestone Sep 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants