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 6 pull requests #98234

Closed
wants to merge 14 commits into from

Conversation

matthiaskrgr
Copy link
Member

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

jyn514 and others added 14 commits June 7, 2022 22:21
This saves a lot of time compiling.
This allows implementing traits that require a raw FD on Arc and Box.

Previously, you'd have to add the function to the trait itself:

```rust
trait MyTrait {
    fn as_raw_fd(&self) -> RawFd;
}

impl<T: MyTrait> MyTrait for Arc<T> {
    fn as_raw_fd(&self) -> RawFd {
        (**self).as_raw_fd()
    }
}
```
4 commits in 4d92f07f34ba7fb7d7f207564942508f46c225d3..8d42b0e8794ce3787c9f7d6d88b02ae80ebe8d19
2022-06-10 01:11:04 +0000 to 2022-06-17 16:46:26 +0000
- Use specific terminology for sparse HTTP-based registry (rust-lang/cargo#10764)
- chore: Upgrade to clap 3.2 (rust-lang/cargo#10753)
- Improve testing framework for http registries (rust-lang/cargo#10738)
- doc: Improve example of using the links field (rust-lang/cargo#10728)
 * no-sequences
 * no-throw-literal
`impl<T: AsRawFd> AsRawFd for {Arc,Box}<T>`

This allows implementing traits that require a raw FD on Arc and Box.

Previously, you'd have to add the function to the trait itself:

```rust
trait MyTrait {
    fn as_raw_fd(&self) -> RawFd;
}

impl<T: MyTrait> MyTrait for Arc<T> {
    fn as_raw_fd(&self) -> RawFd {
        (**self).as_raw_fd()
    }
}
```

In particular, this leads to lots of "multiple applicable items in scope" errors because you have to disambiguate `MyTrait::as_raw_fd` from `AsRawFd::as_raw_fd` at each call site. In generic contexts, when passing the type to a function that takes `impl AsRawFd` it's also sometimes required to use `T: MyTrait + AsRawFd`, which wouldn't be necessary if I could write `MyTrait: AsRawFd`.

After this PR, the code can be simpler:
```rust
trait MyTrait: AsRawFd {}

impl<T: MyTrait> MyTrait for Arc<T> {}
```
…imulacrum

Don't build the compiler before building rust-demangler

This saves a lot of time compiling, since rust-demangler doesn't actually use any unstable features.

This is not quite ideal because it uses ToolStd, not ToolBootstrap, so rust-demangler would be able to add unstable library features in the future. But it's a lot better than before, and `builder.cargo` doesn't currently know how to handle stages other than 0.
…r=Mark-Simulacrum

Add some tests for impossible bounds

Adds test for rust-lang#93008
Adds test for rust-lang#94680
Closes rust-lang#94999
Closes rust-lang#95640
… r=m-ou-se

once cell renamings

This PR does the renamings proposed in rust-lang#74465 (comment)

- Move/rename `lazy::{OnceCell, Lazy}` to `cell::{OnceCell, LazyCell}`
- Move/rename `lazy::{SyncOnceCell, SyncLazy}` to `sync::{OnceLock, LazyLock}`

(I used `Lazy...` instead of `...Lazy` as it seems to be more consistent, easier to pronounce, etc)

`@rustbot` label +T-libs-api -T-libs
Update cargo

4 commits in 4d92f07f34ba7fb7d7f207564942508f46c225d3..8d42b0e8794ce3787c9f7d6d88b02ae80ebe8d19
2022-06-10 01:11:04 +0000 to 2022-06-17 16:46:26 +0000
- Use specific terminology for sparse HTTP-based registry (rust-lang/cargo#10764)
- chore: Upgrade to clap 3.2 (rust-lang/cargo#10753)
- Improve testing framework for http registries (rust-lang/cargo#10738)
- doc: Improve example of using the links field (rust-lang/cargo#10728)
…an-DPC

Add new eslint checks

r? `@Dylan-DPC`
@rustbot rustbot added T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. rollup A PR which is a rollup labels Jun 18, 2022
@Dylan-DPC
Copy link
Member

@bors r+ rollup=never p=5

@bors
Copy link
Contributor

bors commented Jun 18, 2022

📌 Commit 965f499 has been approved by Dylan-DPC

@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 Jun 18, 2022
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=6

@bors
Copy link
Contributor

bors commented Jun 18, 2022

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

@bors
Copy link
Contributor

bors commented Jun 18, 2022

📌 Commit 965f499 has been approved by matthiaskrgr

@matthiaskrgr
Copy link
Member Author

ah oops, thanks @Dylan-DPC , got distracked for a minute 😅

@bors
Copy link
Contributor

bors commented Jun 18, 2022

⌛ Testing commit 965f499 with merge 83a287eeaee9034291280cffa75df12750162af0...

@rust-log-analyzer
Copy link
Collaborator

The job x86_64-gnu-nopt failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
test [ui] src/test/ui/wrong-hashset-issue-42918.rs ... ok

failures:

---- [ui] src/test/ui/trait-bounds/select-param-env-instead-of-blanket.rs stdout ----


1 error: internal compiler error: no errors encountered even though `delay_span_bug` issued
2 
- error: internal compiler error: broken MIR in Item(WithOptConstParam { did: DefId(0:11 ~ select_param_env_instead_of_blanket[b1a3]::foo), const_param_did: None }) (end of phase transition to Optimized) at bb0[1]:
+ error: internal compiler error: broken MIR in Item(WithOptConstParam { did: DefId(0:11 ~ select_param_env_instead_of_blanket[b1a3]::foo), const_param_did: None }) (end of phase transition to Optimized) at bb0[0]:
4                                 encountered `Assign((_1, const 0_usize))` with incompatible types:
5                                 left-hand side has type: <IntFactory as Factory<T>>::Item
6                                 right-hand side has type: usize

The actual stderr differed from the expected stderr.
Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/trait-bounds/select-param-env-instead-of-blanket/select-param-env-instead-of-blanket.stderr
To update references, rerun the tests and pass the `--bless` flag
To update references, rerun the tests and pass the `--bless` flag
To only update this specific test, also pass `--test-args trait-bounds/select-param-env-instead-of-blanket.rs`

error: 1 errors occurred comparing output.
status: exit status: 101
command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/trait-bounds/select-param-env-instead-of-blanket.rs" "-Zthreads=1" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "--json" "future-incompat" "-Ccodegen-units=1" "-Zui-testing" "-Zdeduplicate-diagnostics=no" "-C" "prefer-dynamic" "--out-dir" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/trait-bounds/select-param-env-instead-of-blanket" "-A" "unused" "-Crpath" "-Cdebuginfo=0" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--crate-type=lib" "-Zmir-opt-level=3" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/trait-bounds/select-param-env-instead-of-blanket/auxiliary"
stdout: none
--- stderr -------------------------------
error: internal compiler error: no errors encountered even though `delay_span_bug` issued

error: internal compiler error: broken MIR in Item(WithOptConstParam { did: DefId(0:11 ~ select_param_env_instead_of_blanket[b1a3]::foo), const_param_did: None }) (end of phase transition to Optimized) at bb0[0]:
Some tests failed in compiletest suite=ui mode=ui host=x86_64-unknown-linux-gnu target=x86_64-unknown-linux-gnu
                                encountered `Assign((_1, const 0_usize))` with incompatible types:
                                left-hand side has type: <IntFactory as Factory<T>>::Item
                                right-hand side has type: usize
  --> /checkout/src/test/ui/trait-bounds/select-param-env-instead-of-blanket.rs:41:5
   |
LL |     let mut x: <IntFactory as Factory<T>>::Item = bar::<T>();
   |                                                   ---------- in this inlined function call
LL |     0usize
   |     ^^^^^^
   |
   = note: delayed at compiler/rustc_const_eval/src/transform/validate.rs:128:36
---
note: we would appreciate a bug report: https://github.com/rust-lang/rust/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md

note: rustc 1.63.0-nightly (83a287eea 2022-06-18) running on x86_64-unknown-linux-gnu

note: compiler flags: -Z threads=1 -C codegen-units=1 -Z ui-testing -Z deduplicate-diagnostics=no -C prefer-dynamic -C rpath -C debuginfo=0 --crate-type lib -Z mir-opt-level=3
query stack during panic:
end of query stack
------------------------------------------

@bors
Copy link
Contributor

bors commented Jun 18, 2022

💔 Test failed - checks-actions

@bors bors removed the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Jun 18, 2022
@bors bors added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jun 18, 2022
@matthiaskrgr matthiaskrgr deleted the rollup-2fmyx7w branch July 30, 2022 10:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rollup A PR which is a rollup S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants