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

Rollup of 8 pull requests #68405

Merged
merged 25 commits into from
Jan 21, 2020
Merged

Rollup of 8 pull requests #68405

merged 25 commits into from
Jan 21, 2020

Conversation

JohnTitor
Copy link
Member

Successful merges:

Failed merges:

r? @ghost

XAMPPRocky and others added 25 commits December 30, 2019 14:25
…const-prop

Fixes rust-lang#68264

Previously, I attempted to use
`substitute_normalize_and_test_predicates` to detect unsatisfiable
bounds. Unfortunately, since const-prop runs in a generic environment
(we don't have any of the function's generic parameters substituted),
this could lead to cycle errors when attempting to normalize predicates.

This check is replaced with a more precise check. We now only call
`normalize_and_test_predicates` on predicates that have the possibility
of being proved unsatisfiable - that is, predicates that don't depend
on anything local to the function (e.g. generic parameters). This
ensures that we don't hit cycle errors when we normalize said
predicates, while still ensuring that we detect unsatisfiable
predicates.
Co-Authored-By: Oliver Scherer <github35764891676564198441@oli-obk.de>
The `layout` for the returned allocation of a `realloc` is
only implicitly specified.  This change makes it explicit.
The formatting infrastructure stopped emitting these a while back, and in
removing them we can simplify related code.
These are only called from one place and don't generally support being called
from other places; furthermore, they're the only formatter functions that look
at the `args` field (which a future commit will remove).
These are no longer used by Formatter methods.
fmt::Formatter is still not Send/Sync, but the UI test emitted two errors, for
the dyn Write and the Void inside Formatter. As of this PR, the Void is now
gone, but the dyn Write remains.
Remove appendix from Apache license

Looking at the codebase I noticed an oddity, in that the appendix of how use the Apache licence is still contained in the licence file. We don't put licence headers at the top of all of our files so I don't think we need to keep this. Alternatively we could delete everything above line 191 to have a shorter licence file.
…lnay

Cleanup formatting code

This removes a few leftover positional enum variants that were no longer used.

All details that are changed are unstable (and `#[doc(hidden)]`), so this should
not impact downstream code.
Fix some tests failing in `--pass check` mode

Warnings reported at codegen or linking time either have to be converted to errors (preferable), or the tests for them need to be marked with `// ignore-pass` (as a last resort).

rust-lang@ecd5852 turned them from errors to warnings, but that shouldn't be necessary because it's still clear from the `.stderr` output that the errors are lints and not hard-coded.
…, r=oli-obk

 Filter and test predicates using `normalize_and_test_predicates` for const-prop

Fixes rust-lang#68264

Previously, I attempted to use
`substitute_normalize_and_test_predicates` to detect unsatisfiable
bounds. Unfortunately, since const-prop runs in a generic environment
(we don't have any of the function's generic parameters substituted),
this could lead to cycle errors when attempting to normalize predicates.

This check is replaced with a more precise check. We now only call
`normalize_and_test_predicates` on predicates that have the possibility
of being proved unsatisfiable - that is, predicates that don't depend
on anything local to the function (e.g. generic parameters). This
ensures that we don't hit cycle errors when we normalize said
predicates, while still ensuring that we detect unsatisfiable
predicates.

I haven't been able to come up with a minimization of the Diesel issue - however, I've verified that it compiles successfully.
Fix #[track_caller] and function pointers

Starting with failing tests, fix the miscompilation and ICE caused by `ReifyShim` bug.

Fixes rust-lang#68178.
Add `riscv64gc-unknown-linux-gnu` into target list in build-manifest

Missed in rust-lang#68037

r? @alexcrichton
Added minor clarification to specification of GlobalAlloc::realloc.

The specification of `realloc` is slightly unclear:

```
    /// * `layout` must be the same layout that was used
    ///   to allocate that block of memory,
```
https://github.com/rust-lang/rust/blob/master/src/libcore/alloc.rs#L541-L542

In the case of an `alloc` or `alloc_zeroed` this is fairly evidently the `layout` parameter passed into the original call.  In the case of a `realloc`, this I assume is `layout` modified to contain `new_size`.  However, I could not find this case specified in the documentation.  Thus technically in a sequence of calls to `realloc`, it would be valid to provide the second call to `realloc` the same `layout` as the first call to `realloc`, which is almost certainly not going to be handled correctly.

This PR attempts to clarify the specification.
…tril

rustdoc: Correct order of `async` and `unsafe` in `async unsafe fn`s

The order was swapped in rust-lang#61319 but rustdoc was never updated to match.

r? @GuillaumeGomez
@JohnTitor
Copy link
Member Author

@bors r+ p=8 rollup=never

@bors
Copy link
Contributor

bors commented Jan 20, 2020

📌 Commit f6406f7 has been approved by JohnTitor

@bors bors added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Jan 20, 2020
@JohnTitor JohnTitor added the rollup A PR which is a rollup label Jan 20, 2020
@bors
Copy link
Contributor

bors commented Jan 20, 2020

⌛ Testing commit f6406f7 with merge 06b9450...

bors added a commit that referenced this pull request Jan 20, 2020
Rollup of 8 pull requests

Successful merges:

 - #67734 (Remove appendix from Apache license)
 - #67795 (Cleanup formatting code)
 - #68290 (Fix some tests failing in `--pass check` mode)
 - #68297 ( Filter and test predicates using `normalize_and_test_predicates` for const-prop)
 - #68302 (Fix #[track_caller] and function pointers)
 - #68339 (Add `riscv64gc-unknown-linux-gnu` into target list in build-manifest)
 - #68381 (Added minor clarification to specification of GlobalAlloc::realloc.)
 - #68397 (rustdoc: Correct order of `async` and `unsafe` in `async unsafe fn`s)

Failed merges:

r? @ghost
@bors
Copy link
Contributor

bors commented Jan 21, 2020

☀️ Test successful - checks-azure
Approved by: JohnTitor
Pushing 06b9450 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jan 21, 2020
@bors bors merged commit f6406f7 into rust-lang:master Jan 21, 2020
@JohnTitor JohnTitor deleted the rollup-kj0x4za branch January 21, 2020 03:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. rollup A PR which is a rollup S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.