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

replace Neg example with something more evocative of negation #35830

Merged
merged 1 commit into from
Aug 20, 2016

Conversation

matthew-piziak
Copy link
Contributor

No description provided.

@rust-highfive
Copy link
Collaborator

r? @alexcrichton

(rust_highfive has picked a reviewer for you, use r? to override)

@matthew-piziak
Copy link
Contributor Author

r? @steveklabnik

@@ -470,26 +470,37 @@ rem_impl_float! { f32 f64 }
///
/// # Examples
///
/// A trivial implementation of `Neg`. When `-Foo` happens, it ends up calling
/// `neg`, and therefore, `main` prints `Negating!`.
/// An implementation of `Neg` for `Sign`, which allows the use of `-` to
Copy link
Contributor

Choose a reason for hiding this comment

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

comma might be incorrect here

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I don't believe so. It's a non-restrictive which clause.

Copy link
Contributor

Choose a reason for hiding this comment

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

Correction: the comma might be unnecessary, not strictly incorrect.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I like how relevant your avatar is for this PR, given that it's a cyclic set of invertible elements. :P

Copy link
Contributor Author

@matthew-piziak matthew-piziak Aug 19, 2016

Choose a reason for hiding this comment

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

I stand by the necessity of this comma (Strunk & White II.3), but I certainly won't fight to the death over it. I'm happy to remove it if it truly feels awkward to read.

Copy link
Member

Choose a reason for hiding this comment

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

I would put the comma here, but I also tend to use commas a lot more than most people.

Copy link
Contributor

Choose a reason for hiding this comment

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

no no, you have convinced me. not that you needed to 😄

@mrhota
Copy link
Contributor

mrhota commented Aug 19, 2016

These examples are far clearer. Thanks

@steveklabnik
Copy link
Member

@bors: r+ rollup

thanks!

@bors
Copy link
Contributor

bors commented Aug 19, 2016

📌 Commit c0eccb1 has been approved by steveklabnik

sophiajt pushed a commit to sophiajt/rust that referenced this pull request Aug 19, 2016
…klabnik

replace `Neg` example with something more evocative of negation
sophiajt pushed a commit to sophiajt/rust that referenced this pull request Aug 20, 2016
…klabnik

replace `Neg` example with something more evocative of negation
sophiajt pushed a commit to sophiajt/rust that referenced this pull request Aug 20, 2016
…klabnik

replace `Neg` example with something more evocative of negation
bors added a commit that referenced this pull request Aug 20, 2016
@bors bors merged commit c0eccb1 into rust-lang:master Aug 20, 2016
@matthew-piziak matthew-piziak deleted the not-example branch August 23, 2016 15:13
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