-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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 12 pull requests #48476
Rollup of 12 pull requests #48476
Conversation
Manishearth
commented
Feb 23, 2018
- Successful merges: Do not run the default panic hook inside procedural macros. #47933, Fix nested impl trait lifetimes #48072, Improve tuple struct field access hygiene #48083, detect wrong number of args when type-checking a closure #48123, Add Iterator::try_for_each #48157, lookup exported symbols only when needed. #48219, Overhaul improper_ctypes output #48221, Use sparse bitsets instead of dense ones for NLL results #48245, update tracking issue for nll #48429, Small grammar fix to docs for String::new() #48436, [docs] Minor wording changes to drain_filter docs #48438, Update clippy #48472
- Failed merges:
The fallible version of for_each and the stateless version of try_fold.
Instead of creating inference variables for those argument types, use the trait error-reporting code to give a nicer error.
…enums This dates back to at least rust-lang#26583. At the time, usize and isize were considered ffi-unsafe to nudge people away from them, but this changed in the aforementioned PR, making it inconsistent to complain about it in enum discriminants. In fact, repr(usize) is probably the best way to interface with `enum Foo : size_t { ... }`.
- Always name the non-FFI-safe - Explain *why* the type is not FFI-safe - Stop vaguely gesturing at structs/enums/unions if the non-FFI-safe types occured in a field. The last part is arguably a regression, but it's minor now that the non-FFI-safe type is actually named. Removing it avoids some code duplication.
The suggestion is unconditional, so following it could lead to further errors. This is already the case for the repr(C) suggestion, which makes this acceptable, though not *good*. Checking up-front whether the suggestion can help would be great but applies more broadly (and would require some refactoring to avoid duplicating the checks).
…objects It's unhelpful since raw pointers to trait objects are also FFI-unsafe and casting to a thin raw pointer loses the vtable. There are working solutions that _involve_ raw pointers but they're too complex to explain in one line and have serious trade offs.
reduces the time to emit dep-info and metadata.
Point to the new tracing issue for nll
The docs currently say, "If the closure returns false, it will try again, and call the closure on the next element." But this happens regardless of whether the closure returns true or false.
Do not run the default panic hook inside procedural macros. Fixes rust-lang#47812 r? @nikomatsakis
…=nikomatsakis Fix nested impl trait lifetimes Fixes rust-lang#46464 cc rust-lang#34511 r? @nikomatsakis
…d_access_hygiene, r=petrochenkov Improve tuple struct field access hygiene Fixes rust-lang#47312 by fixing a span bug. r? @nrc
…um-args, r=estebank detect wrong number of args when type-checking a closure Instead of creating inference variables for those argument types, use the trait error-reporting code to give a nicer error. This also improves some other spans for existing tests. Fixes rust-lang#47244 r? @estebank
Add Iterator::try_for_each The fallible version of `for_each` aka the stateless version of `try_fold`. Inspired by @cuviper's comment in rust-lang#45379 (comment) as a more direct and obvious solution than `.map(f).collect::<Result<(), _>>()`. Like `for_each`, no need for an `r` version thanks to overrides in `Rev`. `iterator_try_fold` tracking issue: rust-lang#45594
…erister lookup exported symbols only when needed. reduces the time to compile small file with no optimization by half.
…bank Overhaul improper_ctypes output This snowballed into a rather big set of improvements to the diagnostics of the improper_ctypes lint. See commits for details, including effects of each change on the `compile-fail/improper-ctypes.rs` test (now a UI test), which is pretty gnarly and hopefully not representative of real code, but covers a lot of different error cases. Fixes rust-lang#42050
💔 Test failed - status-appveyor |
@bors retry permissions intermittent? (check-aux passed last time) |
|
⌛ Testing commit b26442a with merge 9dfe47b606ba17ed948ae455bcce4dd723e606c7... |
@bors treeclosed- |
@bors treeclosed=100 (I'm around again) |
💥 Test timed out |
@bors retry |
@bors treeclosed- I will not be awake when this is supposed to land |
☀️ Test successful - status-appveyor, status-travis |
Tested on commit rust-lang/rust@6070d3e. 🎉 clippy-driver on windows: build-fail → test-pass. 🎉 clippy-driver on linux: build-fail → test-pass.