Skip to content

Clarify first use of "elide" in lifetime.md #28842

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

Merged
merged 3 commits into from
Oct 6, 2015
Merged

Conversation

corincerami
Copy link
Contributor

No description provided.

@rust-highfive
Copy link
Contributor

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @pcwalton (or someone else) soon.

If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. The way Github handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.

Please see the contribution instructions for more information.

@Gankra
Copy link
Contributor

Gankra commented Oct 5, 2015

"elide" is standard community terminology for this family of behaviours, fwiw.

I think in this case, this is an improvement though.

@bors r+ rollup

@bors
Copy link
Collaborator

bors commented Oct 5, 2015

📌 Commit ac49eca has been approved by Gankro

@steveklabnik
Copy link
Member

@bors: r-

@steveklabnik
Copy link
Member

So: I do agree that 'elide' is a weird word, but we also call it "lifetime elision" everywhere, and so, in some sense, using this word aids discover-ability.

So I'd like to talk about it before we merge. I'm not sure what the right path of action here is, exactly.

@Gankra
Copy link
Contributor

Gankra commented Oct 5, 2015

I would add a parenthetical mentioning the concept of "elision" here if that's really desirable.

I'd need to go over this section more to get the context, but I was under the impression that this was at a point where we're "not even ready" to discuss lifetime elision in earnest.

@corincerami
Copy link
Contributor Author

That sounds like a reasonable idea. I think it makes sense to at least clarify the use of "elide", even if that just involves including something like "(see 'Lifetime Elision' below)" to the sentence.

@steveklabnik
Copy link
Member

👍 to both things. I think a forward reference here is just fine. Maybe something like

lets you elide (i.e. not write, see "Lifetime Elision" below) them in

?

@corincerami
Copy link
Contributor Author

👍 to that idea.

@steveklabnik
Copy link
Member

Great! Amend this PR and we can :shipit:

@corincerami corincerami changed the title Use a more common word than "elide", e.g. omit Clarify first use of "elide" in lifetime.md Oct 5, 2015
@corincerami
Copy link
Contributor Author

:shipit: 🌈

@@ -70,9 +70,11 @@ fn bar<'a>(x: &'a i32) {
```

The `'a` reads ‘the lifetime a’. Technically, every reference has some lifetime
associated with it, but the compiler lets you elide them in common cases.
associated with it, but the compiler lets you elide (i.e. omit, see ["Lifetime Elision"][lifetime-elision] below) them in common cases.
Copy link
Member

Choose a reason for hiding this comment

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

can you wrap this to 80 chars please?

@steveklabnik
Copy link
Member

@bors: r+ rollup

@bors
Copy link
Collaborator

bors commented Oct 6, 2015

📌 Commit f490f51 has been approved by steveklabnik

@bors
Copy link
Collaborator

bors commented Oct 6, 2015

⌛ Testing commit f490f51 with merge e7b6056...

@bors bors merged commit f490f51 into rust-lang:master Oct 6, 2015
@corincerami corincerami deleted the patch-1 branch October 6, 2015 20:23
@corincerami
Copy link
Contributor Author

🌈

Manishearth added a commit to Manishearth/rust that referenced this pull request Oct 14, 2015
…ision_link, r=alexcrichton

This link was added in rust-lang#28842 but doesn't work at https://doc.rust-lang.org/nightly/book/lifetimes.html. What works in my markdown preview doesn't work live, and vice versa.
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

Successfully merging this pull request may close these issues.

6 participants