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

book: replace example I do not understand #37956

Merged
merged 1 commit into from
Dec 25, 2016
Merged

book: replace example I do not understand #37956

merged 1 commit into from
Dec 25, 2016

Conversation

tshepang
Copy link
Member

No description provided.

@rust-highfive
Copy link
Collaborator

r? @steveklabnik

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

@leoyvens
Copy link
Contributor

That refers to running a server, servers run in an infinite loop so an example that runs a server would hang your tests.

@GuillaumeGomez
Copy link
Member

I don't find this change useful. :-/

@@ -460,8 +460,9 @@ not actually pass as a test.
```

The `no_run` attribute will compile your code, but not run it. This is
important for examples such as "Here's how to start up a network service,"
which you would want to make sure compile, but might run in an infinite loop!
important for examples such as "Here's how to start up a network service",
Copy link
Contributor

Choose a reason for hiding this comment

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

Having the comma inside the quotations is correct here, as the docs are written in American English. (I remember seeing this specified somewhere...)

Copy link
Member

Choose a reason for hiding this comment

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

yes!

@steveklabnik
Copy link
Member

r=me after the comma fix

@tshepang
Copy link
Member Author

@bors: r? @steveklabnik

@steveklabnik
Copy link
Member

Re-starting travis; hopefully it's fixed by now.

@@ -460,8 +460,9 @@ not actually pass as a test.
```

The `no_run` attribute will compile your code, but not run it. This is
important for examples such as "Here's how to start up a network service,"
which you would want to make sure compile, but might run in an infinite loop!
important for examples such as "Here's how to retrive a web page,"
Copy link
Contributor

Choose a reason for hiding this comment

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

sp: "retrieve"

important for examples such as "Here's how to start up a network service,"
which you would want to make sure compile, but might run in an infinite loop!
important for examples such as "Here's how to retrive a web page,"
which you would want to ensure it compiles, but might be run in a test
Copy link
Contributor

Choose a reason for hiding this comment

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

the original grammar is odd but correct, since "examples" is plural and so the sentence is "examples [..], which you would want to ensure compile." Adding "it" is incorrect because "which" is already the subject of "compile". Alternatively you could write e.g. "an example such as [..]: you would want to ensure it compiles, but it might be..." which is probably less confusing overall.

@steveklabnik
Copy link
Member

@tshepang ping! I find @goffrie 's comments to be good, any interest in updating this PR?

@tshepang
Copy link
Member Author

will do

@tshepang
Copy link
Member Author

updated @steveklabnik, thanks @goffrie

@steveklabnik
Copy link
Member

@bors: r+ rollup

@bors
Copy link
Contributor

bors commented Dec 24, 2016

📌 Commit d8ee074 has been approved by steveklabnik

steveklabnik added a commit to steveklabnik/rust that referenced this pull request Dec 24, 2016
book: replace example I do not understand
bors added a commit that referenced this pull request Dec 24, 2016
Rollup of 14 pull requests

- Successful merges: #37956, #38013, #38297, #38480, #38497, #38502, #38505, #38513, #38521, #38549, #38554, #38557, #38568, #38572
- Failed merges:
@bors bors merged commit d8ee074 into rust-lang:master Dec 25, 2016
@tshepang tshepang deleted the patch-2 branch December 25, 2016 22:17
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.

8 participants