-
Couldn't load subscription status.
- Fork 13.9k
Rollup of 7 pull requests #37937
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
Rollup of 7 pull requests #37937
Conversation
GuillaumeGomez
commented
Nov 22, 2016
- Successful merges: Provide hint when cast needs a dereference #37442, Type walker small vector #37760, Clarify the reference's status. #37836, Add a regression test for issue 23699. #37851, Add missing examples for Ipv6Addr #37859, Add missing examples for SocketAddrV4 #37913, Add some internal docs links for Args/ArgsOs #37925
- Failed merges:
The former wording only gave part of the picture, we want to be crystal clear about this.
For a given code: ```rust vec![0.0].iter().map(|s| s as i16).collect::<Vec<i16>>(); ``` display: ```nocode error: casting `&f64` as `i16` is invalid --> foo.rs:2:35 | 2 | vec![0.0].iter().map(|s| s as i16).collect::<Vec<i16>>(); | - ^^^ cannot cast `&f64` as `i16` | | | did you mean `*s`? ``` instead of: ```nocode error: casting `&f64` as `i16` is invalid --> <anon>:2:30 | 2 | vec![0.0].iter().map(|s| s as i16).collect(); | ^^^^^^^^ | = help: cast through a raw pointer first ```
The change also adds the missing `SmallVec::truncate` method.
|
r? @brson (rust_highfive has picked a reviewer for you, use r? to override) |
|
@bors: r+ p=1 |
|
📌 Commit 3960357 has been approved by |
|
⌛ Testing commit 3960357 with merge 89191c1... |
|
💔 Test failed - auto-win-msvc-64-opt-rustbuild |
3960357 to
ccdc26f
Compare
…ndturner Provide hint when cast needs a dereference For a given code: ``` rust vec![0.0].iter().map(|s| s as i16).collect::<Vec<i16>>(); ``` display: ``` nocode error: casting `&f64` as `i16` is invalid --> file3.rs:2:35 | 2 | vec![0.0].iter().map(|s| s as i16).collect::<Vec<i16>>(); | - ^^^ | | | did you mean `*s`? ``` instead of: ``` nocode error: casting `&f64` as `i16` is invalid --> <anon>:2:30 | 2 | vec![0.0].iter().map(|s| s as i16).collect(); | ^^^^^^^^ | = help: cast through a raw pointer first ``` Fixes rust-lang#37338.
… r=arielb1 Type walker small vector These two changes avoid allocations on some hot paths and speed up a few workloads (some from rustc-benchmarks, as well as the workload from rust-lang#36799) by 1--2%.
…ence-comment, r=GuillaumeGomez Clarify the reference's status. The former wording only gave part of the picture, we want to be crystal clear about this. /cc @petrochenkov, who had concerns about rust-lang#37820
Add a regression test for issue 23699. This should close rust-lang#23699
Add missing examples for SocketAddrV4 r? @steveklabnik cc @frewsxcv
…eklabnik Add some internal docs links for Args/ArgsOs In many places the docs link to other sections and I noticed it was lacking here. Not sure if there is a standard for if inter-linking is appropriate.
…es, r=eddyb Move the myriad-closures.rs test case to run-pass-full test suite. r? @eddyb
…ctors, r=nikomatsakis ICH: Add test case for struct constructor expressions. r? @nikomatsakis
|
@bors: r+ p=1 |
|
📌 Commit d2c600a has been approved by |