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 19 pull requests #130127

Closed
wants to merge 53 commits into from

Commits on Aug 10, 2024

  1. Configuration menu
    Copy the full SHA
    2dbc976 View commit details
    Browse the repository at this point in the history

Commits on Aug 26, 2024

  1. Add a run-make test for checking that certain rustc_ crates build o…

    …n stable
    Kobzol authored and lqd committed Aug 26, 2024
    Configuration menu
    Copy the full SHA
    893413d View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7957140 View commit details
    Browse the repository at this point in the history
  3. run test in tmp dir and emit artifacts there

    otherwise the test would build in the source root's `target` folder
    lqd committed Aug 26, 2024
    Configuration menu
    Copy the full SHA
    d9794a9 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    2190c28 View commit details
    Browse the repository at this point in the history
  5. separate the crates to test from the test setup

    it'll be easier to see and update the list: the other cmd args
    can just be ignored
    lqd committed Aug 26, 2024
    Configuration menu
    Copy the full SHA
    0577035 View commit details
    Browse the repository at this point in the history
  6. remove unneeded type ascription

    lqd committed Aug 26, 2024
    Configuration menu
    Copy the full SHA
    f1df0c5 View commit details
    Browse the repository at this point in the history

Commits on Sep 1, 2024

  1. Configuration menu
    Copy the full SHA
    4ee58db View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f2696ab View commit details
    Browse the repository at this point in the history

Commits on Sep 2, 2024

  1. Use sysroot crates maximally in rustc_codegen_gcc.

    This shrinks `compiler/rustc_codegen_gcc/Cargo.lock` quite a bit. The
    only remaining dependencies in `compiler/rustc_codegen_gcc/Cargo.lock`
    are `gccjit`, `lang_tester`, and `boml`, all of which aren't used in any
    other compiler crates.
    
    The commit also reorders and adds comments to the `extern crate` items
    so they match those in miri.
    nnethercote committed Sep 2, 2024
    Configuration menu
    Copy the full SHA
    747f680 View commit details
    Browse the repository at this point in the history
  2. address review comments

    lqd committed Sep 2, 2024
    Configuration menu
    Copy the full SHA
    a178559 View commit details
    Browse the repository at this point in the history

Commits on Sep 3, 2024

  1. Pin memchr to 2.5.0 in the library rather than rustc_ast

    The latest versions of `memchr` experience LTO-related issues when
    compiling for windows-gnu [1], so needs to be pinned. The issue is
    present in the standard library.
    
    `memchr` has been pinned in `rustc_ast`, but since the workspace was
    recently split, this pin no longer has any effect on library crates.
    
    Resolve this by adding `memchr` as an _unused_ dependency in `std`,
    pinned to 2.5. Additionally, remove the pin in `rustc_ast` to allow
    non-library crates to upgrade to the latest version.
    
    Link: rust-lang#127890 [1]
    tgross35 committed Sep 3, 2024
    Configuration menu
    Copy the full SHA
    8f0ea94 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    9c671a1 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    07c0585 View commit details
    Browse the repository at this point in the history

Commits on Sep 6, 2024

  1. Configuration menu
    Copy the full SHA
    7dd1be1 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f6d2cfc View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    ae661dd View commit details
    Browse the repository at this point in the history
  4. Make download-ci-llvm = true check if CI llvm is available

    and make it the default for the compiler profile, as to prevent
    unnecessarily checking out `src/llvm-project` with `"if-unchanged"`.
    Urgau committed Sep 6, 2024
    Configuration menu
    Copy the full SHA
    5f367bb View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    c1ff6fd View commit details
    Browse the repository at this point in the history
  6. Fix enabling wasm-component-ld to match other tools

    It was [pointed out recently][comment] that enabling `wasm-component-ld`
    as a host tool is different from other host tools. This commit refactors
    the logic to match by deduplicating selection of when to build other
    tools and then using the same logic for `wasm-component-ld`.
    
    [comment]: rust-lang#127866 (comment)
    alexcrichton committed Sep 6, 2024
    Configuration menu
    Copy the full SHA
    c15469a View commit details
    Browse the repository at this point in the history

Commits on Sep 7, 2024

  1. Configuration menu
    Copy the full SHA
    c788dcc View commit details
    Browse the repository at this point in the history
  2. Rename variant AddrOfRegion of RegionVariableOrigin to `BorrowReg…

    …ion`
    
    because "Borrow" is the more idiomatic Rust term than "AddrOf".
    gurry committed Sep 7, 2024
    Configuration menu
    Copy the full SHA
    c0b0627 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    f7d4da6 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    03e0c8e View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    cfe85a3 View commit details
    Browse the repository at this point in the history
  6. librustdoc::config: removed Input from Options

    The `librustdoc::config::Options` struct no longer includes
    `rustc_session::config::Input`. This is so that Input can be optional.
    In rfc#3662, the crate input is not required if `--merge=finalize`.
    
    Replacing Input with Option<Input> was decided against. In most places
    that Input is needed, it should be statically known to not be optional
    (means fewer unwraps). We just want to have an Input-free Options in
    librustdoc::main_args, where we can run the write shared procedure.
    EtomicBomb authored and ethan committed Sep 7, 2024
    Configuration menu
    Copy the full SHA
    3782251 View commit details
    Browse the repository at this point in the history
  7. rfc#3662 changes under unstable flags

    * All new functionality is under unstable options
    * Adds `--merge=shared|none|finalize` flags
    * Adds `--parts-out-dir=<crate specific directory>` for `--merge=none`
    to write cross-crate info file for a single crate
    * Adds `--include-parts-dir=<previously specified directory>` for
    `--merge=finalize` to write cross-crate info files
    * update tests/run-make/rustdoc-default-output/rmake.rs golden
    EtomicBomb authored and ethan committed Sep 7, 2024
    Configuration menu
    Copy the full SHA
    2e1cba6 View commit details
    Browse the repository at this point in the history
  8. add tests for behavior in rfc#3662

    * Adds tests for the behavior from rfc#3662 in `tests/rustdoc/`
    EtomicBomb committed Sep 7, 2024
    Configuration menu
    Copy the full SHA
    548b6e1 View commit details
    Browse the repository at this point in the history

Commits on Sep 8, 2024

  1. add some FIXME(const-hack)

    RalfJung committed Sep 8, 2024
    Configuration menu
    Copy the full SHA
    3de6838 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ec11001 View commit details
    Browse the repository at this point in the history
  3. Option, Result: put the &mut variants of 'copied' under the same feat…

    …ure as the '&' variants
    RalfJung committed Sep 8, 2024
    Configuration menu
    Copy the full SHA
    f7b4f4a View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    11d51aa View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    5f3fdd1 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    7626015 View commit details
    Browse the repository at this point in the history

Commits on Sep 9, 2024

  1. Rollup merge of rust-lang#119229 - mati865:update-mingw-toolchain, r=…

    …jieyouxu,petrochenkov
    
    Update mingw-w64 + GNU toolchain
    
    The list of packaged tools and their versions is available at: https://github.com/niXman/mingw-builds-binaries/releases/tag/14.1.0-rt_v12-rev0
    
    Fixes: rust-lang#112368
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    4e0c58f View commit details
    Browse the repository at this point in the history
  2. Rollup merge of rust-lang#128345 - sthibaul:hurd-amd64, r=Urgau

    added support for GNU/Hurd on x86_64
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    aa18e98 View commit details
    Browse the repository at this point in the history
  3. Rollup merge of rust-lang#128667 - its-the-shrimp:rustdoc_json_types_…

    …rename, r=aDotInTheVoid
    
    rustdoc: normalise type/field names
    
    Updates rust-lang#100961
    
    - `Import` -> `Use`, to better reflect the terminology of Rust & its syntax
    - `TypeBinding` -> `AssocItemConstraint`, to sync up with `clean`
    - `FnDecl` -> `FunctionSignature`, because that's what it is
    - `Header` -> `FunctionHeader`, because `Header` is a very word that's very heavily loaded with different meanings
    - `ItemEnum::AssocType`: `default` -> `type`, because those items appear in `impl` blocks as well, where they're _not_ the "default"
    - `ItemEnum::AssocConst`: `default` -> `value`, see the previous point
    - `ForeignType` -> `ExternType`, because "foreign" is not the right word there
    - boolean fields' names made to consistently be a phrase that can be a yes/no answer, e.g. `async` -> `is_async`
    
    The docs of `ItemEnum::AssocType::type_` & of `ItemEnum::AssocConst::value` are also updated to be up to date with the clarification of the name of the fields
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    6c50e48 View commit details
    Browse the repository at this point in the history
  4. Rollup merge of rust-lang#128939 - bjorn3:windows_cg_clif_component, …

    …r=albertlarsan68
    
    Distribute rustc_codegen_cranelift for Windows
    
    With support for raw-dylib recently added to cg_clif, and inline assembly support working on Windows for quite a while now, all blockers for distributing cg_clif on Windows that I mentioned in rust-lang#81746 (comment) are fixed now.
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    1a645f1 View commit details
    Browse the repository at this point in the history
  5. Rollup merge of rust-lang#129337 - EtomicBomb:rfc, r=notriddle

    rustdoc rfc#3662 changes under unstable flags
    
    * All new functionality is under unstable options
    * Adds `--merge=shared|none|finalize` flags
    * Adds `--parts-out-dir=<crate specific directory>` for `--merge=none`
    to write cross-crate info file for a single crate
    * Adds `--include-parts-dir=<previously specified directory>` for
    `--merge=finalize` to write cross-crate info files
    * `tests/rustdoc/` tests for the new flags
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    2a97310 View commit details
    Browse the repository at this point in the history
  6. Rollup merge of rust-lang#129473 - Urgau:fix-llvm-if-unchanged, r=onu…

    …r-ozkan
    
    use  `download-ci-llvm=true` in the default compiler config
    
    rust-lang@1ca2708 made it so that the `src/llvm-project` submodule has to be checkout for `download-ci-llvm = "if-unchanged"` to know if the submodule has been changed, but that is not required, if the submodule hasn't been checkout it cannot have been modified.
    
    ~~This PR restore the previous behavior by only updating the submodule if it has already been checkout.~~
    
    This PR makes `download-ci-llvm = true` check if CI llvm is available and make it the default for the compiler profile, as to prevent unnecessarily checking out `src/llvm-project` with `"if-unchanged"`.
    
    r? ```@onur-ozkan```
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    feda28d View commit details
    Browse the repository at this point in the history
  7. Rollup merge of rust-lang#129529 - lqd:stable-new-solver, r=Kobzol

    Add test to build crates used by r-a on stable
    
    r? `````@Kobzol`````
    
    I've opened other PRs for this one to work and they've landed already. I cherry-picked your commit, and added the last remaining pieces we needed I think.
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    c5de40e View commit details
    Browse the repository at this point in the history
  8. Rollup merge of rust-lang#129624 - tgross35:cargo-update, r=Mark-Simu…

    …lacrum
    
    Adjust `memchr` pinning and run `cargo update`
    
    try-job: x86_64-mingw
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    0d8ad47 View commit details
    Browse the repository at this point in the history
  9. Rollup merge of rust-lang#129876 - nnethercote:more-sysroot-rustc_cod…

    …egen_gcc, r=Mark-Simulacrum
    
    Use sysroot crates maximally in `rustc_codegen_gcc`.
    
    This shrinks `compiler/rustc_codegen_gcc/Cargo.lock` quite a bit. The only remaining dependencies in `compiler/rustc_codegen_gcc/Cargo.lock` are `gccjit`, `lang_tester`, and `boml`, all of which aren't used in any other compiler crates.
    
    The commit also reorders and adds comments to the `extern crate` items so they match those in miri.
    
    r? `@Mark-Simulacrum`
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    0785e3d View commit details
    Browse the repository at this point in the history
  10. Rollup merge of rust-lang#130025 - Urgau:missing_docs-expect, r=petro…

    …chenkov
    
    Also emit `missing_docs` lint with `--test` to fulfil expectations
    
    This PR removes the "test harness" suppression of the `missing_docs` lint to be able to fulfil `#[expect]` (expectations) as it is now "relevant".
    
    I think the goal was to maybe avoid false-positive while linting on public items under `#[cfg(test)]` but with effective visibility we should no longer have any false-positive.
    
    Another possibility would be to query the lint level and only emit the lint if it's of expect level, but that is even more hacky.
    
    Fixes rust-lang#130021
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    844cc98 View commit details
    Browse the repository at this point in the history
  11. Rollup merge of rust-lang#130034 - alexcrichton:fix-some-wasm-compone…

    …nt-ld-comments, r=onur-ozkan
    
     Fix enabling wasm-component-ld to match other tools
    
    It was [pointed out recently][comment] that enabling `wasm-component-ld` as a host tool is different from other host tools. This commit refactors the logic to match by deduplicating selection of when to build other tools and then using the same logic for `wasm-component-ld`.
    
    While here I also fixed a typo pointed out in rust-lang#126967 (review)
    
    [comment]: rust-lang#127866 (comment)
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    4faf77d View commit details
    Browse the repository at this point in the history
  12. Rollup merge of rust-lang#130048 - nebulark:runmake_llvm_pdbutil, r=j…

    …ieyouxu
    
    run-make-support: Add llvm-pdbutil
    
    Add llvm-pdbutil to run-make-support, so we can write better unit tests for PDB specific features.
    
    r? ``@jieyouxu``
    ``@rustbot`` label: +O-windows
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    8678d8d View commit details
    Browse the repository at this point in the history
  13. Rollup merge of rust-lang#130068 - madsmtm:deployment-target-test, r=…

    …jieyouxu
    
    Test codegen when setting deployment target
    
    Test our codegen in different scenarios when setting the deployment target. There are many places here where this is still incorrect, these will be fixed in rust-lang#129342, rust-lang#129367 and rust-lang#129369. See rust-lang#129432 for the bigger picture.
    
    Tested locally using:
    ```console
    ./x test tests/run-make/apple-deployment-target --target="aarch64-apple-darwin,aarch64-apple-ios,aarch64-apple-ios-macabi,aarch64-apple-ios-sim,aarch64-apple-tvos,aarch64-apple-tvos-sim,aarch64-apple-visionos,aarch64-apple-visionos-sim,aarch64-apple-watchos,aarch64-apple-watchos-sim,arm64_32-apple-watchos,armv7s-apple-ios,i386-apple-ios,x86_64-apple-darwin,x86_64-apple-ios,x86_64-apple-ios-macabi,x86_64-apple-tvos,x86_64-apple-watchos-sim,x86_64h-apple-darwin"
    ```
    
    The only Apple targets that aren't tested by the above command are:
    - `arm64e-apple-darwin`, failed to build, see rust-lang/cc-rs#1205.
    - `armv7k-apple-watchos`, failed to link, see rust-lang#130071.
    - `arm64e-apple-ios`, failed to link, see rust-lang#130085.
    - `i686-apple-darwin`, requires a bit of setup and an older machine, see [the docs](https://doc.rust-lang.org/nightly/rustc/platform-support/i686-apple-darwin.html).
    - `i386-apple-ios` requires you to set `IPHONEOS_DEPLOYMENT_TARGET=10.0` for the test helpers to work, will be fixed by rust-lang/cc-rs#1030.
    
    But all of this is as it was before this PR.
    
    Fixes rust-lang#47825, since we now have a test that compiles a `dylib` for `aarch64-apple-ios`.
    
    Split out from rust-lang#129342, see that for a little bit of the review that this has gone through already.
    
    r? petrochenkov
    
    `@rustbot` label O-apple
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    6def68a View commit details
    Browse the repository at this point in the history
  14. Rollup merge of rust-lang#130070 - gurry:rename-regionkind-addof-to-r…

    …ef, r=compiler-errors
    
    Rename variant `AddrOfRegion` of `RegionVariableOrigin` to `BorrowRegion`
    
    because "Borrow" is the more idiomatic Rust term than "AddrOf".
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    1a7b68a View commit details
    Browse the repository at this point in the history
  15. Rollup merge of rust-lang#130087 - RalfJung:option-const-iter, r=work…

    …ingjubilee
    
    remove 'const' from 'Option::iter'
    
    This is kind of pointless to be a `const fn` since you can't do anything with the iterator. It is also the only `const fn iter*` in the entire standard library. It probably got constified when `~const` traits got added everywhere, and then was forgotten to be de-constified when that was undone.
    
    The rest of the const_option feature seems like it can reasonably be stabilized, but this one IMO should not be stabilized, and it's not worth creating a new tracking issue.
    
    Cc rust-lang#67441
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    10f66fb View commit details
    Browse the repository at this point in the history
  16. Rollup merge of rust-lang#130090 - RalfJung:result-copied, r=Noratrieb

    make Result::copied unstably const
    
    The corresponding `Option::copied` is unstably const, so seems reasonable to do the same here.
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    d2353ef View commit details
    Browse the repository at this point in the history
  17. Rollup merge of rust-lang#130092 - zslayton:master, r=jieyouxu

    Fixes typo in wasm32-wasip2 doc comment
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    d6288ce View commit details
    Browse the repository at this point in the history
  18. Rollup merge of rust-lang#130107 - RalfJung:const-ptr-is-null, r=oli-obk

    const: make ptr.is_null() stop execution on ambiguity
    
    This seems better than saying `false` -- saying `false` is in fact actively unsound if `NonNull` then uses this to permit putting this pointer inside of it, but at runtime it turns out to be null.
    
    Part of rust-lang#74939
    Cc `@rust-lang/wg-const-eval`
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    1d371d0 View commit details
    Browse the repository at this point in the history
  19. Rollup merge of rust-lang#130115 - eduardosm:needless-returns-libs, r…

    …=workingjubilee
    
    Remove needless returns detected by clippy in libraries
    workingjubilee committed Sep 9, 2024
    Configuration menu
    Copy the full SHA
    61b447d View commit details
    Browse the repository at this point in the history