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 7 pull requests #78711

Merged
merged 43 commits into from
Nov 3, 2020
Merged

Rollup of 7 pull requests #78711

merged 43 commits into from
Nov 3, 2020

Conversation

m-ou-se
Copy link
Member

@m-ou-se m-ou-se commented Nov 3, 2020

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

arlosi and others added 30 commits October 14, 2020 15:09
Fixes compilation without -Ztrim-diagnostic-paths=no
Per their documentation, the `max_value()` and `min_value()` associated functions have been superseded by the `MAX` and `MIN` associated constants since Rust 1.43 and are considered "soft deprecated", with all uses currently being replaced in the rustc repo.
Prefer numeric associated constants in example
Fixes bootstrapping of rustc using cg_clif

Fixes rust-lang#1097
They have no effect there, but were silently accepted.
…ces` lint

This lint was incorrectly suggesting casting a function to a pointer without
specifying generic type parameters or const generics. This would cause a
compiler error since the missing parameters couldn't be inferred. This commit
fixed the suggestion and added a few tests with generics.
(From the PR feedback.)

Co-authored-by: Esteban Küber <esteban@kuber.com.ar>
bjorn3 and others added 13 commits November 2, 2020 18:54
Even more information to try and debug rust-lang#78665.
Add support for SHA256 source file hashing

Adds support for `-Z src-hash-algorithm sha256`, which became available in LLVM 11.

Using an older version of LLVM will cause an error `invalid checksum kind` if the hash algorithm is set to sha256.

r? `@eddyb`
cc rust-lang#70401 `@est31`
…=jyn514

Sync rustc_codegen_cranelift

This fixes bootstrapping of rustc using cg_clif again. It regressed a while before rust-lang#77975 got merged.

Fixes https://github.com/bjorn3/rustc_codegen_cranelift/issues/743
…-trait-impl, r=estebank

Improve errors about #[deprecated] attribute

This change:

1. Turns `#[deprecated]` on a trait impl block into an error, which fixes rust-lang#78625;
2. Changes these and other errors about `#[deprecated]` to use the span of the attribute instead of the item; and
3. Turns this error into a lint, to make sure it can be capped with `--cap-lints` and doesn't break any existing dependencies.

Can be reviewed per commit.

---
Example:
```rust
struct X;

#[deprecated = "a"]
impl Default for X {
    #[deprecated = "b"]
    fn default() -> Self {
        X
    }
}
```

Before:
```
error: This deprecation annotation is useless
 --> src/main.rs:6:5
  |
6 | /     fn default() -> Self {
7 | |         X
8 | |     }
  | |_____^
```

After:
```
error: this `#[deprecated]' annotation has no effect
 --> src/main.rs:3:1
  |
3 | #[deprecated = "a"]
  | ^^^^^^^^^^^^^^^^^^^ help: try removing the deprecation attribute
  |
  = note: `#[deny(useless_deprecated)]` on by default

error: this `#[deprecated]' annotation has no effect
 --> src/main.rs:5:5
  |
5 |     #[deprecated = "b"]
  |     ^^^^^^^^^^^^^^^^^^^ help: try removing the deprecation attribute
```
Corrected suggestion for generic parameters in `function_item_references` lint

This commit handles functions with generic type parameters like you pointed out as well as const generics. Also this is probably a minor thing, but the type alias you used in the example doesn't show up so the suggestion right now would be `size_of::<[u8; 16]> as fn() ->`. This is because the lint checker works with MIR instead of HIR. I don't think we can get the alias at that point, but let me know if I'm wrong and there's a way to fix this. Also I put you as the reviewer, but I'm not sure if you want to review it or if it makes more sense to ask one of the original reviewers of this lint.
closes rust-lang#78571
…acrum

Suggest library/std when running all stage 0 tests

r? ``@Mark-Simulacrum``
cc ``@ijackson``

For context, this came out of a discord conversation where ``@ijackson`` was running `test --stage 1` when they were only adding doc-tests to the standard library.
Show more error information in lldb_batchmode

Even more information to try and debug rust-lang#78665.
…, r=Mark-Simulacrum

Fix panic in bootstrap for non-workspace path dependencies.

If you add a `path` dependency to a `Cargo.toml` that is located outside of the workspace, then the `in_tree_crates` function can panic because it finds a path dependency that is not defined (since it uses `cargo metadata --no-deps`).  This fixes it by skipping over those entries, which are usually not things you select on the command-line.

Fixes rust-lang#78617
@rustbot rustbot added the rollup A PR which is a rollup label Nov 3, 2020
@m-ou-se
Copy link
Member Author

m-ou-se commented Nov 3, 2020

@bors r+ p=7 rollup=never

@bors
Copy link
Contributor

bors commented Nov 3, 2020

📌 Commit a65507b has been approved by m-ou-se

@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 Nov 3, 2020
@bors
Copy link
Contributor

bors commented Nov 3, 2020

⌛ Testing commit a65507b with merge 5629309...

@bors
Copy link
Contributor

bors commented Nov 3, 2020

☀️ Test successful - checks-actions
Approved by: m-ou-se
Pushing 5629309 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Nov 3, 2020
@bors bors merged commit 5629309 into rust-lang:master Nov 3, 2020
@rustbot rustbot added this to the 1.49.0 milestone Nov 3, 2020
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.