Skip to content

Better document trait objects. #184

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 1 commit into from
Dec 30, 2017
Merged

Conversation

Havvy
Copy link
Contributor

@Havvy Havvy commented Dec 29, 2017

Fixes #171.

@Havvy
Copy link
Contributor Author

Havvy commented Dec 29, 2017

Travis failure is from merging a different PR with a bad example, not from this PR.

src/types.md Outdated
> the same, if the base traits differ, the type is different. For example,
> `Send + Sync` is a different type from `Sync + Send`. See [issue 33140].

> Warning: Inlcuding the same auto trait multiple times is allowed, and each
Copy link
Member

Choose a reason for hiding this comment

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

small typo: including

src/types.md Outdated
@@ -459,16 +459,18 @@ fn main() {
In this example, the trait `Printable` occurs as a trait object in both the
type signature of `print`, and the cast expression in `main`.

### Trait Object Lifetimes
Copy link
Contributor

Choose a reason for hiding this comment

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

"Trait Object Lifetime Bounds"?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Avoided messing with the verbiage of this section at all (I don't understand what it's conveying yet myself, as I haven't put much thought into it), but that's a better title for the section, so changed it.

@steveklabnik steveklabnik merged commit 1d791b5 into rust-lang:master Dec 30, 2017
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.

3 participants