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 10 pull requests #110310

Closed
wants to merge 30 commits into from

Conversation

matthiaskrgr
Copy link
Member

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

seanlinsley and others added 30 commits March 16, 2023 11:07
For larger applications it's important that users set `RUST_MIN_STACK`
at the start of their program because `min_stack` caches the value.
Not doing so can lead to their `env::set_var` call surprisingly not having any effect.
this test was added for rust 0.4 and doesn't test anything specific.
The repro originally relied on extern functions which are now just
ordinary methods. It's also a run pass test even though `main` has
been commented out.
This is necessary for the subsequent commits.
Re-phrase in a way that handles input values being either 0 or
negative.
…rename usages of bound_impl_subject to impl_subject
This patch updates the error reporting when Safe Transmute is not
possible between 2 types by including the reason.

Also, fix some small bugs that occur when computing the `Answer` for
transmutability.
Clarify that RUST_MIN_STACK may be internally cached

For larger applications it's important that users set `RUST_MIN_STACK` at the start of their program because [`min_stack`](https://github.com/rust-lang/rust/blob/7d3e03666a93bd2b0f78b3933f9305832af771a5/library/std/src/sys_common/thread.rs) caches the value. Not doing so can lead to their `env::set_var` call surprisingly not having any effect.

In my own testing `RUST_MIN_STACK` had no effect until I moved it to the top of `main()`. Hopefully this clarification in the docs will help others going forward.
…-errors, r=compiler-errors

Improve safe transmute error reporting

This patch updates the error reporting when Safe Transmute is not possible between 2 types by including the reason.

Also, fix some small bugs that occur when computing the `Answer` for transmutability.
Remove obsolete test case

This test case was supposed to cover issue rust-lang#31109 at some point.
It never did anything, as the issue was still open at the time of its creation.
When the issue was resolved, the `issue31109` test case was created,
making the existence of this test pointless.
don't uniquify regions when canonicalizing

uniquifying causes a bunch of issues, most notably it causes `AliasEq(<?x as Trait<'a>>::Assoc, <?x as Trait<'a>>::Assoc)` to result in ambiguity because both `normalizes-to` paths result in ambiguity and substs equate should trivially succeed but doesn't because we uniquified `'a` to two different regions.

I originally added uniquification to make it easier to deal with requirement 6 from the dev-guide: https://rustc-dev-guide.rust-lang.org/solve/trait-solving.html#requirements

> ### 6. Trait solving must be (free) lifetime agnostic
>
> Trait solving during codegen should have the same result as during typeck. As we erase
> all free regions during codegen we must not rely on them during typeck. A noteworthy example
> is special behavior for `'static`.

cc rust-lang/rustc-dev-guide#1671

Relying on regions being identical may cause ICE during MIR typeck, but even without this PR we can end up relying on that as type inference vars can resolve to types which contain an identical region. Let's land this and deal with any ICE that crop up as we go. Will look at this issue again before stabilization.

r? ``@compiler-errors``
…r=lcnr

Assemble `Unpin` candidates specially for generators in new solver

Fixes compiler-errors/next-solver-hir-issues#16

r? `@lcnr`
…kanonur

fix: use `--retry-connrefused` in curl invocations of bootstrap download

helps with rust-lang#110178.
…h726

Remove all but one of the spans in `BoundRegionKind::BrAnon`

There are only three places where `BoundRegionKind::BrAnon` uses `Some(span)` instead of `None`. Two of them are easy to remove, which this PR does.

r? ``@jackh726``
…ve, r=notriddle

rustdoc: Correctly handle built-in compiler proc-macros as proc-macro and not macro

Part of rust-lang#110111.

There were actually one issue split in two parts:
 * Compiler built-in proc-macro were incorrectly considered as macros and not proc-macros.
 * Re-exports of compiler built-in proc-macros were considering them as macros.

Both issues can be fixed by looking at the `MacroKind` variant instead of just relying on information extracted later on.

r? `@fmease`
…ses, r=thomcc

Cover edge cases for {f32, f64}.hypot() docs

Fixes rust-lang#88944

The Euclidean distance is a more general way to express what these functions do, and covers the edge cases of zero and negative inputs.

Does not cover the case of non-normal input values (as the [POSIX docs](https://pubs.opengroup.org/onlinepubs/9699919799.2008edition/) do), but the docs for the rest of the functions in these modules do not address this, I assumed it was not desired.
…ct, r=compiler-errors

Switch to `EarlyBinder` for `impl_subject` query

Part of the work to finish rust-lang#105779.

Several queries `X` have a `bound_X` variant that wraps the output in `EarlyBinder`. This adds `EarlyBinder` to the return type of the `impl_subject` query and removes `bound_impl_subject`.

r? ``@lcnr``
@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) 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. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver) rollup A PR which is a rollup labels Apr 14, 2023
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=10

@bors
Copy link
Contributor

bors commented Apr 14, 2023

📌 Commit 8775f89 has been approved by matthiaskrgr

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Apr 14, 2023
@bors
Copy link
Contributor

bors commented Apr 14, 2023

⌛ Testing commit 8775f89 with merge 342819003dedc264fc77745d9ad345654f0275ec...

@bors
Copy link
Contributor

bors commented Apr 14, 2023

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Apr 14, 2023
@rust-log-analyzer
Copy link
Collaborator

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

Click to see the possible cause of the failure (guessed by this bot)
configure: 
configure: run `python /checkout/x.py --help`
Attempting with retry: make prepare
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
    found:    e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855
    expected: 9a13a8c8e16028d0e07608da8fbd0ea5b51d9d425230712adcbac679ef5fef9d
Traceback (most recent call last):
  File "/checkout/src/bootstrap/bootstrap.py", line 965, in <module>
  File "/checkout/src/bootstrap/bootstrap.py", line 965, in <module>
    main()
  File "/checkout/src/bootstrap/bootstrap.py", line 950, in main
    bootstrap(args)
  File "/checkout/src/bootstrap/bootstrap.py", line 914, in bootstrap
    build.download_toolchain()
  File "/checkout/src/bootstrap/bootstrap.py", line 436, in download_toolchain
    self._download_component_helper(filename, pattern, tarball_suffix)
  File "/checkout/src/bootstrap/bootstrap.py", line 473, in _download_component_helper
    verbose=self.verbose,
  File "/checkout/src/bootstrap/bootstrap.py", line 51, in get
    raise RuntimeError("failed verification")
make: *** [prepare] Error 1
Command failed. Attempt 2/5:
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
    found:    e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855
    expected: 9a13a8c8e16028d0e07608da8fbd0ea5b51d9d425230712adcbac679ef5fef9d
Traceback (most recent call last):
  File "/checkout/src/bootstrap/bootstrap.py", line 965, in <module>
  File "/checkout/src/bootstrap/bootstrap.py", line 965, in <module>
    main()
  File "/checkout/src/bootstrap/bootstrap.py", line 950, in main
    bootstrap(args)
  File "/checkout/src/bootstrap/bootstrap.py", line 914, in bootstrap
    build.download_toolchain()
  File "/checkout/src/bootstrap/bootstrap.py", line 436, in download_toolchain
    self._download_component_helper(filename, pattern, tarball_suffix)
  File "/checkout/src/bootstrap/bootstrap.py", line 473, in _download_component_helper
    verbose=self.verbose,
  File "/checkout/src/bootstrap/bootstrap.py", line 51, in get
    raise RuntimeError("failed verification")
make: *** [prepare] Error 1
Command failed. Attempt 3/5:
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
    found:    e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855
    expected: 9a13a8c8e16028d0e07608da8fbd0ea5b51d9d425230712adcbac679ef5fef9d
Traceback (most recent call last):
  File "/checkout/src/bootstrap/bootstrap.py", line 965, in <module>
  File "/checkout/src/bootstrap/bootstrap.py", line 965, in <module>
    main()
  File "/checkout/src/bootstrap/bootstrap.py", line 950, in main
    bootstrap(args)
  File "/checkout/src/bootstrap/bootstrap.py", line 914, in bootstrap
    build.download_toolchain()
  File "/checkout/src/bootstrap/bootstrap.py", line 436, in download_toolchain
    self._download_component_helper(filename, pattern, tarball_suffix)
  File "/checkout/src/bootstrap/bootstrap.py", line 473, in _download_component_helper
    verbose=self.verbose,
  File "/checkout/src/bootstrap/bootstrap.py", line 51, in get
    raise RuntimeError("failed verification")
make: *** [prepare] Error 1
Command failed. Attempt 4/5:
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
    found:    e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855
    expected: 9a13a8c8e16028d0e07608da8fbd0ea5b51d9d425230712adcbac679ef5fef9d
Traceback (most recent call last):
  File "/checkout/src/bootstrap/bootstrap.py", line 965, in <module>
  File "/checkout/src/bootstrap/bootstrap.py", line 965, in <module>
    main()
  File "/checkout/src/bootstrap/bootstrap.py", line 950, in main
    bootstrap(args)
  File "/checkout/src/bootstrap/bootstrap.py", line 914, in bootstrap
    build.download_toolchain()
  File "/checkout/src/bootstrap/bootstrap.py", line 436, in download_toolchain
    self._download_component_helper(filename, pattern, tarball_suffix)
  File "/checkout/src/bootstrap/bootstrap.py", line 473, in _download_component_helper
    verbose=self.verbose,
  File "/checkout/src/bootstrap/bootstrap.py", line 51, in get
    raise RuntimeError("failed verification")
make: *** [prepare] Error 1
Command failed. Attempt 5/5:
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
spurious failure, trying again
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
downloading https://static.rust-lang.org/dist/2023-03-07/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz
curl: option --retry-connrefused: is unknown
curl: try 'curl --help' or 'curl --manual' for more information
    found:    e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855
    expected: 9a13a8c8e16028d0e07608da8fbd0ea5b51d9d425230712adcbac679ef5fef9d
Traceback (most recent call last):
  File "/checkout/src/bootstrap/bootstrap.py", line 965, in <module>
  File "/checkout/src/bootstrap/bootstrap.py", line 965, in <module>
    main()
  File "/checkout/src/bootstrap/bootstrap.py", line 950, in main
    bootstrap(args)
  File "/checkout/src/bootstrap/bootstrap.py", line 914, in bootstrap
    build.download_toolchain()
  File "/checkout/src/bootstrap/bootstrap.py", line 436, in download_toolchain
    self._download_component_helper(filename, pattern, tarball_suffix)
  File "/checkout/src/bootstrap/bootstrap.py", line 473, in _download_component_helper
    verbose=self.verbose,
  File "/checkout/src/bootstrap/bootstrap.py", line 51, in get
    raise RuntimeError("failed verification")
make: *** [prepare] Error 1
The command has failed after 5 attempts.

@matthiaskrgr matthiaskrgr deleted the rollup-ngy5xhd branch March 16, 2024 18:19
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-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) 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. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver)
Projects
None yet
Development

Successfully merging this pull request may close these issues.