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

Tracking issue for RFC 1857: Stabilize drop order #43034

Closed
aturon opened this issue Jul 3, 2017 · 7 comments
Closed

Tracking issue for RFC 1857: Stabilize drop order #43034

aturon opened this issue Jul 3, 2017 · 7 comments
Labels
B-RFC-approved Blocker: Approved by a merged RFC but not yet implemented. C-tracking-issue Category: A tracking issue for an RFC or an unstable feature. T-lang Relevant to the language team, which will review and decide on the PR/issue.

Comments

@aturon
Copy link
Member

aturon commented Jul 3, 2017

RFC

For this RFC, what's needed is documentation. There's no behavioral change or feature-flag stabilization.

@aturon aturon added B-RFC-approved Blocker: Approved by a merged RFC but not yet implemented. T-lang Relevant to the language team, which will review and decide on the PR/issue. labels Jul 3, 2017
@aochagavia
Copy link
Contributor

Besides documentation, I think a couple of tests would be useful as well to prevent accidentally changing the order.

@aochagavia
Copy link
Contributor

@aturon In the RFC I mentioned updating the book, but upon second thought relying on a particular drop order seems to be a niche use case. Therefore it seems reasonable to me to omit it in the book and only mention it in the reference. Do you agree with that?

@vitalyd
Copy link

vitalyd commented Jul 8, 2017

The book should mention that the drop order is specified, but can refer the reader to the reference for elaboration.

@aochagavia
Copy link
Contributor

@steveklabnik @carols10cents I am trying to find a good place in the book to put tell that drop order is specified. I guess if we were to do this it would go in the chapter about drop. Unfortunately, the example uses a struct with only one field, so we cannot use the example to talk about drop order. Maybe we could add an extra field and then explain which field is dropped first? Then, we could link to the reference for more information.

I am still not sure about mentioning drop order in the book, so I am also interested in your opinion regarding that.

@steveklabnik
Copy link
Member

Yes, we should mention it; we already do in the lifetimes section, I believe. The drop chapter is the right place though, and another example is a good idea.

@arielb1
Copy link
Contributor

arielb1 commented Jul 11, 2017

The "panic during initialization drops elements in reverse order" is actually a part of the "temporary lifetimes" rules, which are described in https://github.com/nikomatsakis/rust-memory-model/issues/17. Do we want to document them?

steveklabnik added a commit to steveklabnik/rust that referenced this issue Jul 13, 2017
Add regression tests to ensure stable drop order

Work towards rust-lang#43034

I think this is all we need to do on the testing front regarding RFC 1857
@Mark-Simulacrum Mark-Simulacrum added the C-tracking-issue Category: A tracking issue for an RFC or an unstable feature. label Jul 27, 2017
@Centril
Copy link
Contributor

Centril commented Sep 15, 2018

I believe there's nothing left to do here, so closing.

@Centril Centril closed this as completed Sep 15, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
B-RFC-approved Blocker: Approved by a merged RFC but not yet implemented. C-tracking-issue Category: A tracking issue for an RFC or an unstable feature. T-lang Relevant to the language team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

7 participants