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

Rustup #11048

Merged
merged 35 commits into from
Jun 30, 2023
Merged

Rustup #11048

merged 35 commits into from
Jun 30, 2023

Conversation

flip1995
Copy link
Member

r? @ghost

changelog: none

albertlarsan68 and others added 30 commits April 26, 2023 15:27
…rors

Rollup of 7 pull requests

Successful merges:

 - #111670 (Require that const param tys implement `ConstParamTy`)
 - #111914 (CFI: Fix cfi with async: transform_ty: unexpected GeneratorWitness(Bi…)
 - #112030 (Migrate `item_trait_alias` to Askama)
 - #112150 (Support 128-bit atomics on all x86_64 Apple targets)
 - #112174 (Fix broken link)
 - #112190 (Improve comments on `TyCtxt` and `GlobalCtxt`.)
 - #112193 (Check tuple elements are `Sized` in `offset_of`)

Failed merges:

 - #112071 (Group rfcs tests)

r? `@ghost`
`@rustbot` modify labels: rollup
…r-errors

Rename `impl_defaultness` to `defaultness`

Since this isn't just about the `impl`.
… few misc issues, added collect to UnordItems
…fixed a few misc issues, added collect to UnordItems
…iler-errors

Uplift `clippy::undropped_manually_drops` lint

This PR aims at uplifting the `clippy::undropped_manually_drops` lint.

## `undropped_manually_drops`

(warn-by-default)

The `undropped_manually_drops` lint check for calls to `std::mem::drop` with a value of `std::mem::ManuallyDrop` which doesn't drop.

### Example

```rust
struct S;
drop(std::mem::ManuallyDrop::new(S));
```

### Explanation

`ManuallyDrop` does not drop it's inner value so calling `std::mem::drop` will not drop the inner value of the `ManuallyDrop` either.

-----

Mostly followed the instructions for uplifting an clippy lint described here: rust-lang/rust#99696 (review)

`@rustbot` label: +I-lang-nominated
r? compiler

-----

For Clippy:

changelog: Moves: Uplifted `clippy::undropped_manually_drops` into rustc
Only use it when the type alias contains an opaque type.

Also does wf-checking on such type aliases.
…aber

Better error for non const `PartialEq` call generated by `match`

Resolves #90237
Make `{Arc,Rc,Weak}::ptr_eq` ignore pointer metadata

FCP completed in rust-lang/rust#103763 (comment)

Closes #103763
Add a fully fledged `Clause` type, rename old `Clause` to `ClauseKind`

Does two basic things before I put up a more delicate set of PRs (along the lines of #112714, but hopefully much cleaner) that migrate existing usages of `ty::Predicate` to `ty::Clause` (`predicates_of`/`item_bounds`/`ParamEnv::caller_bounds`).

1. Rename `Clause` to `ClauseKind`, so it's parallel with `PredicateKind`.
2. Add a new `Clause` type which is parallel to `Predicate`.
    * This type exposes `Clause::kind(self) -> Binder<'tcx, ClauseKind<'tcx>>` which is parallel to `Predicate::kind` 😸

The new `Clause` type essentially acts as a newtype wrapper around `Predicate` that asserts that it is specifically a `PredicateKind::Clause`. Turns out from experimentation[^1] that this is not negative performance-wise, which is wonderful, since this a much simpler design than something that requires encoding the discriminant into the alignment bits of a predicate kind, or something else like that...

r? ``@lcnr`` or ``@oli-obk``

[^1]: rust-lang/rust#112714 (comment)
Syntactically accept `become` expressions (explicit tail calls experiment)

This adds `ast::ExprKind::Become`, implements parsing and properly gates the feature.

cc `@scottmcm`
Rollup of 6 pull requests

Successful merges:

 - #112632 (Implement PartialOrd for `Vec`s over different allocators)
 - #112759 (Make closure_saved_names_of_captured_variables a query. )
 - #112772 (Add a fully fledged `Clause` type, rename old `Clause` to `ClauseKind`)
 - #112790 (Syntactically accept `become` expressions (explicit tail calls experiment))
 - #112830 (More codegen cleanups)
 - #112844 (Add retag in MIR transform: `Adt` for `Unique` may contain a reference)

r? `@ghost`
`@rustbot` modify labels: rollup
bors and others added 3 commits June 26, 2023 13:51
…ler-errors,Nilstrieb

`hir`: Add `Become` expression kind (explicit tail calls experiment)

This adds `hir::ExprKind::Become` alongside ast lowering. During hir-thir lowering we currently lower `become` as `return`, so that we can partially test `become` without ICEing.

cc `@scottmcm`
r? `@Nilstrieb`
@flip1995
Copy link
Member Author

@bors r+ p=1

@flip1995
Copy link
Member Author

@bors p=10

@flip1995
Copy link
Member Author

@bors r+ p=10

@flip1995
Copy link
Member Author

@bors r+

@bors
Copy link
Contributor

bors commented Jun 29, 2023

📌 Commit 3d25840 has been approved by flip1995

It is now in the queue for this repository.

@matthiaskrgr
Copy link
Member

@bors ping

@bors
Copy link
Contributor

bors commented Jun 29, 2023

😪 I'm awake I'm awake

@matthiaskrgr
Copy link
Member

@bors r=flip1995

@bors
Copy link
Contributor

bors commented Jun 29, 2023

💡 This pull request was already approved, no need to approve it again.

@bors
Copy link
Contributor

bors commented Jun 29, 2023

📌 Commit 3d25840 has been approved by flip1995

It is now in the queue for this repository.

@bors
Copy link
Contributor

bors commented Jun 29, 2023

⌛ Testing commit 3d25840 with merge fae2d65...

bors added a commit that referenced this pull request Jun 29, 2023
Rustup

r? `@ghost`

changelog: none
@bors
Copy link
Contributor

bors commented Jun 29, 2023

💔 Test failed - checks-action_remark_test

@flip1995
Copy link
Member Author

@bors r+

@bors
Copy link
Contributor

bors commented Jun 30, 2023

📌 Commit 30d08d3 has been approved by flip1995

It is now in the queue for this repository.

@bors
Copy link
Contributor

bors commented Jun 30, 2023

⌛ Testing commit 30d08d3 with merge 2c40b99...

@bors
Copy link
Contributor

bors commented Jun 30, 2023

☀️ Test successful - checks-action_dev_test, checks-action_remark_test, checks-action_test
Approved by: flip1995
Pushing 2c40b99 to master...

@bors bors merged commit 2c40b99 into rust-lang:master Jun 30, 2023
@flip1995 flip1995 deleted the rustup branch June 30, 2023 14:49
@bors bors mentioned this pull request Jun 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.