-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Conversation
(rust_highfive has picked a reviewer for you, use r? to override) |
That refers to running a server, servers run in an infinite loop so an example that runs a server would hang your tests. |
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", |
There was a problem hiding this comment.
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...)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes!
r=me after the comma fix |
@bors: r? @steveklabnik |
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," |
There was a problem hiding this comment.
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 |
There was a problem hiding this comment.
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.
will do |
updated @steveklabnik, thanks @goffrie |
@bors: r+ rollup |
📌 Commit d8ee074 has been approved by |
book: replace example I do not understand
No description provided.