-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Rollup of 10 pull requests #26150
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
Rollup of 10 pull requests #26150
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Member
steveklabnik
commented
Jun 9, 2015
- Successful merges: reference: get consistent by removing unneeded whitespace #26111, trpl: Semantic accuracy in borrow scope rules. #26125, Explain interaction with if and | in patterns #26129, fix comments in example about types #26131, fix example in comments about demangling #26132, remove stuff about #define #26133, Clarify confusing sentence in TRPL: FFI #26134, Expand a bit on clone() in Dining Philosophers #26136, Fix some copyediting in TRPL: method-syntax #26140, Make note about static and dtors #26144
- Failed merges:
On MSVC there are two ways that the CRT can be linked, either statically or dynamically. Each object file produced by the compiler is compiled against msvcrt (a dll) or libcmt (a static library). When the linker is dealing with more than one object file, it requires that all object files link to the same CRT, or else the linker will spit out some errors. For now, compile code with `-MD` as it seems to appear more often in C libraries so we'll stick with the same trend.
The text claimed 'any borrow must last for a _smaller_ scope than the owner', however the accurate way of describing the comparison is inclusive (i.e., 'less than or equal to' vs. 'less than').
On MSVC there are two ways that the CRT can be linked, either statically or dynamically. Each object file produced by the compiler is compiled against msvcrt (a dll) or libcmt (a static library). When the linker is dealing with more than one object file, it requires that all object files link to the same CRT, or else the linker will spit out some errors. For now, compile code with `-MD` as it seems to appear more often in C libraries so we'll stick with the same trend.
This obscures more than it helps. Fixes rust-lang#25573
After talking with @graydon on #rust-internals, this is hopefully clarifying. Fixes rust-lang#25586
As this example got changed, we stopped showing how to return self as the first example, so this text is outdated. Fixes rust-lang#25803
The text claimed 'any borrow must last for a _smaller_ scope than the owner', however the accurate way of describing the comparison is inclusive (i.e., 'less than or equal to' vs. 'less than').
…chton Hi, I think the comments are wrong in the example and this PR offers my suggested fix.
…crichton Hi, I think the second example fails rule 3 described immediately above. This PR fixes that.
This obscures more than it helps. Fixes rust-lang#25573
After talking with @graydon on #rust-internals, this is hopefully clarifying. Fixes rust-lang#25586 @mkpankov, what do you think?
As this example got changed, we stopped showing how to return self as the first example, so this text is outdated. Fixes rust-lang#25803
…crichton Fixes rust-lang#25851 I am 99% sure this is true for all `static`s and not just `static mut`, yes?
r? @pcwalton (rust_highfive has picked a reviewer for you, use r? to override) |
@bors: r+ p=100 |
📌 Commit 6b6b380 has been approved by |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.