about summary refs log tree commit diff
path: root/src/tools
AgeCommit message (Collapse)AuthorLines
2025-08-29Rollup merge of #145947 - nnethercote:workspace-members-2, r=KobzolStuart Cook-18/+18
Add more to the `[workspace.dependencies]` section in the top-level `Cargo.toml` Following on from rust-lang/rust#145740. r? `@Kobzol`
2025-08-29compiler: Add `{x86_64,aarch64,riscv64gc}-unknown-managarm-mlibc` targetsno92-0/+3
Co-authored-by: Dennis Bonke <dennis@managarm.org>
2025-08-28std: Start supporting WASIp2 nativelyAlex Crichton-1/+5
This commit is the start of an effort to support WASIp2 natively in the standard library. Before this commit the `wasm32-wasip2` target behaved exactly like `wasm32-wasip1` target by importing APIs from the core wasm module `wasi_snapshot_preview1`. These APIs are satisfied by the `wasm-component-ld` target by using an [adapter] which implements WASIp1 in terms of WASIp2. This adapter comes at a cost, however, in terms of runtime indirection and instantiation cost, so ideally the adapter would be removed entirely. The purpose of this adapter was to provide a smoother on-ramp from WASIp1 to WASIp2 when it was originally created. The `wasm32-wasip2` target has been around for long enough now that it's much more established. Additionally the only thing historically blocking using WASIp2 directly was implementation effort. Work is now underway to migrate wasi-libc itself to using WASIp2 directly and now seems as good a time as any to migrate the Rust standard library too. Implementation-wise the milestones here are: * The `wasm32-wasip2` target now also depends on the `wasi` crate at version 0.14.* in addition to the preexisting dependency of 0.11.*. The 0.14.* release series binds WASIp2 APIs instead of WASIp1 APIs. * Some preexisting naming around `mod wasi` or `wasi.rs` was renamed to `wasip1` where appropriate. For example `std::sys::pal::wasi` is now called `std::sys::pal::wasip1`. * More platform-specific WASI modules are now split between WASIp1 and WASIp2. For example getting the current time, randomness, and process arguments now use WASIp2 APIs directly instead of using WASIp1 APIs that require an adapter. It's worth pointing out that this PR does not migrate the entire standard library away from using WASIp1 APIs on the `wasm32-wasip2` target. Everything related to file descriptors and filesystem APIs is still using WASIp1. Migrating that is left for a future PR. In the meantime the goal of this change is to lay the groundwork necessary for migrating in the future. Eventually the goal is to drop the `wasi` 0.11.* dependency on the `wasm32-wasip2` target (the `wasm32-wasip1` target will continue to retain this dependency). [adapter]: https://github.com/bytecodealliance/wasmtime/blob/main/crates/wasi-preview1-component-adapter/README.md
2025-08-28When mapping next-solver's `dyn` type, add `Self` (aka. bound var ^1.0) to ↵Chayim Refael Friedman-1/+70
auto traits' substitutions Chalk represents dyn types as a list of predicate, the self type should be there. The next solver represents them quite differently. The `Self` was forgotten for the auto trait case.
2025-08-28Rollup merge of #142472 - GuillaumeGomez:doc-attribute-attribute, r=fmeaseGuillaume Gomez-0/+4
Add new `doc(attribute = "...")` attribute Fixes rust-lang/rust#141123. The implementation and purpose of this new `#[doc(attribute = "...")]` attribute is very close to `#[doc(keyword = "...")]`. Which means that luckily for us, most of the code needed was already in place and `@Noratrieb` nicely wrote a first draft that helped me implement this new attribute very fast. Now with all this said, there is one thing I didn't do yet: adding a `rustdoc-js-std` test. I added GUI tests with search results for attributes so should be fine but I still plan on adding one for it once documentation for builtin attributes will be written into the core/std libs. You can test it [here](https://rustdoc.crud.net/imperio/doc-attribute-attribute/foo/index.html). cc `@Noratrieb` `@Veykril`
2025-08-28Don't require a full `InferenceTable` for `CastTy`Chayim Refael Friedman-59/+52
A DB is enough.
2025-08-28Add progress bars to more places in analysis-statsChayim Refael Friedman-3/+52
Namely, mir lowering, const eval and IDE things.
2025-08-28Add new `doc(attribute = "...")` attributeGuillaume Gomez-0/+4
2025-08-28Merge pull request #4539 from Stypox/tracing-docsRalf Jung-0/+292
Add documentation for tracing
2025-08-28Rollup merge of #145953 - robertbastian:master, r=ManishearthStuart Cook-6/+6
Update `icu_list` to 2.0 This updates the `icu_list` crate, which is used for error formatting, from 1.5 to 2.0.
2025-08-28Rollup merge of #145926 - Zalathar:no-libtest, r=jieyouxuStuart Cook-88/+53
compiletest: Remove several remnants of the old libtest-based executor I noticed a few bits of low-hanging cleanup that are possible now that the non-libtest executor is well and truly established.
2025-08-28Add documentation for tracingStypox-0/+292
2025-08-28Add `rustc-demangle` to `[workspace.dependencies]`.Nicholas Nethercote-1/+1
2025-08-28Add `rustc-hash` to `[workspace.dependencies]`.Nicholas Nethercote-2/+2
2025-08-28Add `indexmap` to `[workspace.dependencies]`.Nicholas Nethercote-1/+1
2025-08-28Add `tempfile` to `[workspace.dependencies]`.Nicholas Nethercote-2/+2
2025-08-28Add `serde_json` to `[workspace.dependencies]`.Nicholas Nethercote-10/+10
2025-08-28Add `libc` to `[workspace.dependencies]`.Nicholas Nethercote-2/+2
2025-08-28Use default locale fallback dataRobert Bastian-1/+1
2025-08-28Bump icu_list to 2.0Robert Bastian-5/+5
2025-08-28Attach the db in one more place in highlightingChayim Refael Friedman-1/+2
2025-08-27fix target-pointer-width in testsWaffle Lapkin-1/+1
2025-08-27accept integer `target-pointer-width` in compiletestWaffle Lapkin-7/+1
2025-08-27Merge pull request #20547 from ChayimFriedman2/highlight-related-unsafe-scopeLaurențiu Nicola-10/+44
fix: In highlight_related, when on an unsafe block, don't highlight unsafe operations of other unsafe blocks
2025-08-27Stabilize BTree{Map,Set}::extract_ifSidney Cammeresi-1/+0
2025-08-27Auto merge of #145909 - weihanglo:update-cargo, r=weihanglobors-0/+0
Update cargo submodule 3 commits in 623d536836b4cde09ce38609232a024d5b25da81..a6c58d43051d01d83f55a3e61ef5f5b2b0dd6bd9 2025-08-22 19:05:52 +0000 to 2025-08-26 23:05:12 +0000 - test: avoid hardcoded target spec json (rust-lang/cargo#15880) - test(add): Cover some frontmatter corner cases (rust-lang/cargo#15886) - Add more context to publish-failed error message (rust-lang/cargo#15879) r? ghost
2025-08-27Remove several remnants of the old libtest-based executorZalathar-88/+53
2025-08-27Rollup merge of #145885 - madsmtm:lldb-inherit-tcc, r=KobzolMatthias Krüger-0/+29
Inherit TCC in debuginfo tests on macOS macOS has a system for propagating folder permissions, which LLDB disables when spawning processes, which in turn causes debuginfo tests to spam the user with repeated pop-ups asking for permissions. See the code comment for details, as well as the following video for an example of how this looks in practice: https://github.com/user-attachments/assets/1e54f5b8-9130-4b59-8e92-1db1e58fb361 I stumbled upon the incantation to fix this (`settings set target.inherit-tcc true`) while investigating slowdowns when spawning newly created binaries due to XprotectService, see [this Zulip thread](https://rust-lang.zulipchat.com/#narrow/channel/246057-t-cargo/topic/build.20scripts.20slow.20on.20macOS.3F). This would allow me to no longer have a `build.build-dir = "/Users/madsmtm/rust-build"` workaround in my `bootstrap.toml`.
2025-08-27Rollup merge of #145740 - nnethercote:workspace-members, r=KobzolMatthias Krüger-4/+4
Introduce a `[workspace.dependencies`] section in the top-level `Cargo.toml` It lets us avoid a lot of repetition of crate versions, etc. I've just done a few as a start. Many more can be done in follow-ups. r? `@Kobzol`
2025-08-27Rollup merge of #145335 - clarfonthey:wtf8-core-alloc, r=Mark-SimulacrumMatthias Krüger-0/+1
Move WTF-8 code from std into core and alloc This is basically a small portion of rust-lang/rust#129411 with a smaller scope. It *does not*\* affect any public APIs; this code is still internal to the standard library. It just moves the WTF-8 code into `core` and `alloc` so it can be accessed by `no_std` crates like `backtrace`. > \* The only public API this affects is by adding a `Debug` implementation to `std::os::windows::ffi::EncodeWide`, which was not present before. This is due to the fact that `core` requires `Debug` implementations for all types, but `std` does not (yet) require this. Even though this was ultimately changed to be a wrapper over the original type, not a re-export, I decided to keep the `Debug` implementation so it remains useful. Like we do with ordinary strings, the tests are still located entirely in `alloc`, rather than splitting them into `core` and `alloc`. ---- Reviewer note: for ease of review, this is split into three commits: 1. Moving the original files into their new "locations" 2. Actually modifying the code to compile. 3. Removing aesthetic changes that were made so that the diff for commit 2 was readable. You can review commits 1 and 3 to verify these claims, but commit 2 contains the majority of the changes you should care about. ---- API changes: `impl Debug for std::os::windows::ffi::EncodeWide`
2025-08-27Merge ref '269d5b56bcfd' from rust-lang/rustThe Miri Cronjob Bot-8/+87
Pull recent changes from https://github.com/rust-lang/rust via Josh. Upstream ref: 269d5b56bcfdf2be82213e72ef9a2e4c592a8c6b Filtered ref: a221b1d3ebb78ec8a01dcb1fe6bb165378e2f5c9 This merge was created using https://github.com/rust-lang/josh-sync.
2025-08-27Prepare for merging from rust-lang/rustThe Miri Cronjob Bot-1/+1
This updates the rust-version file to 269d5b56bcfdf2be82213e72ef9a2e4c592a8c6b.
2025-08-27Merge pull request #20527 from ChayimFriedman2/cache-next-solverShoyu Vanilla (Flint)-66/+140
perf: Cache trait solving across queries in the same revision
2025-08-27Add `itertools` to `[workspace.dependencies]`.Nicholas Nethercote-1/+1
2025-08-27Add `tracing` to `[workspace.dependencies]`.Nicholas Nethercote-3/+3
2025-08-26Update cargo submoduleWeihang Lo-0/+0
2025-08-26Rollup merge of #145892 - jdonszelmann:codegen-fn-attrs-foreign-item, r=bjorn3Samuel Tardieu-4/+3
add a flag to codegen fn attrs for foreign items r? `@ghost` refiled to rerun CI
2025-08-26In highlight_related, when on an unsafe block, don't highlight unsafe ↵Chayim Refael Friedman-10/+44
operations of other unsafe blocks
2025-08-26Remove `SolverDefId::ForeignId`Chayim Refael Friedman-7/+4
Replace it with normal `SolverDefId::TypeAliasId`. The split caused a very funny bug where code was getting `TypeAliasId` where it expected `ForeignId`, because `TypeAliasId` had a `From` impl from `hir_def::TypeAliasId` and `ForeignId` had not, plus a careless `into()`. I could've fixed this specific bug but opted to remove the split instead; currently, it just provides more room for bugs, as we don't have typed IDs for the solver anyway, and even when we'll have (hopefully), that doesn't seem like a very useful distinction, for example in hir-def foreign types are just `TypeAliasId` with some flags. Constructing a test for this isn't trivial; the trivial test (creating a foreign type, even proving a trait bound for it) fails to fail before the change, probably because we don't use the new solver everywhere yet so we don't trigger this specific code path.
2025-08-27fix: Prevent invalid transformation in 'Replace match with if let' assistsgasho-1/+23
2025-08-26Bless clippy tests.Mara Bos-22/+38
2025-08-26Inherit TCC in debuginfo tests on macOSMads Marquart-0/+29
2025-08-26add a flag to codegen fn attrs for foreign itemsJana Dönszelmann-4/+3
2025-08-26Merge pull request #20399 from rust-lang/veykril/push-klrwvmzokqwuShoyu Vanilla (Flint)-2/+2
Enable warning logs by default
2025-08-26Merge pull request #20534 from A4-Tacks/tog-macro-delim-semicolonShoyu Vanilla (Flint)-3/+33
Fix ExprStmt delete semicolon for toggle_macro_delimiter
2025-08-26Merge pull request #20509 from A4-Tacks/fix-move-guard-to-arm-indentShoyu Vanilla (Flint)-13/+57
Fix indent for move_guard_to_arm_body
2025-08-26Merge pull request #20520 from ChayimFriedman2/reborrowShoyu Vanilla (Flint)-5/+88
feat: Add an option to remove reborrows from adjustment inlay hints
2025-08-26Merge pull request #20537 from ChayimFriedman2/new-solver-normalizeShoyu Vanilla (Flint)-6/+45
fix: Normalize all types when finishing inference
2025-08-26Rollup merge of #145858 - alexcrichton:update-wasm-component-ld, r=lqdStuart Cook-2/+1
Update wasm-component-ld dependency Keeping it up-to-date with the latest changes/features.
2025-08-26Rollup merge of #145845 - Kobzol:fix-distcheck, r=jieyouxuStuart Cook-0/+6
Make `x test distcheck` self-contained Before, the checked components were extracted under the checked out source root, which caused us to test some weird combination of tarball + checkout sources/aritfacts/configuration. Now `x test distcheck` works with an external temporary directory instead, which should make it self-contained. I also moved some config from the Dockerfile to the test itself, and fixed an issue in tidy that caused `x test tidy` to fail on tarball sources. I also removed `.args(&builder.config.configure_args)`, because it was passing all kinds of crap from the CI config to the distcheck step, which was making it less reproducible. Fixes: https://github.com/rust-lang/rust/issues/145183 r? ```@jieyouxu``` try-job: x86_64-gnu-distcheck