about summary refs log tree commit diff
path: root/src/tools/tidy
AgeCommit message (Collapse)AuthorLines
2025-06-27Rollup merge of #139858 - oli-obk:new-const-traits-syntax, r=fee1-deadMatthias Krüger-1/+0
New const traits syntax This PR only affects the AST and doesn't actually change anything semantically. All occurrences of `~const` outside of libcore have been replaced by `[const]`. Within libcore we have to wait for rustfmt to be bumped in the bootstrap compiler. This will happen "automatically" (when rustfmt is run) during the bootstrap bump, as rustfmt converts `~const` into `[const]`. After this we can remove the `~const` support from the parser Caveat discovered during impl: there is no legacy bare trait object recovery for `[const] Trait` as that snippet in type position goes down the slice /array parsing code and will error r? ``@fee1-dead`` cc ``@nikomatsakis`` ``@traviscross`` ``@compiler-errors``
2025-06-26Rename `tilde const` test files to `conditionally const`Oli Scherer-1/+0
2025-06-25make `tidy-alphabetical` use a natural sortFolkert de Vries-2/+204
2025-06-24Update wasm-component-ld to 0.5.14Alex Crichton-0/+1
This brings in a few updates to the bundled `wasm-component-ld` dependency used by the `wasm32-wasip2` target. This primarily includes support for upcoming component model async/WASIp3 support which will be convenient to have native support for a few months from now.
2025-06-24Auto merge of #142959 - bjorn3:sync_cg_clif-2025-06-24, r=bjorn3bors-0/+3
Subtree sync for rustc_codegen_cranelift The main highlight this time is a Cranelift update. r? `@ghost` `@rustbot` label +A-codegen +A-cranelift +T-compiler
2025-06-24Rollup merge of #142704 - tgross35:remove-concat_idents, r=fee1-deadGuillaume Gomez-3/+1
Remove the deprecated unstable `concat_idents!` macro In [rust-lang/rust#137653], the lang and libs-API teams did a joint FCP to deprecate and eventually remove the long-unstable `concat_idents!` macro. The deprecation is landing in 1.88, so do the removal here (target version 1.90). This macro has been superseded by the more recent `${concat(...)}` metavariable expression language feature, which avoids some of the limitations of `concat_idents!`. The metavar expression is unstably available under the [`macro_metavar_expr_concat`] feature. History is mildly interesting here: `concat_idents!` goes back to 2011 when it was introduced with 513276e595f8 ("Add #concat_idents[] and #ident_to_str[]"). The syntax looks a bit different but it still works about the same: let asdf_fdsa = "<.<"; assert(#concat_idents[asd,f_f,dsa] == "<.<"); assert(#ident_to_str[use_mention_distinction] == "use_mention_distinction"); (That test existed from introduction until its removal here.) Closes: https://github.com/rust-lang/rust/issues/29599 [rust-lang/rust#137653]: https://github.com/rust-lang/rust/pull/137653 [`macro_metavar_expr_concat`]: https://github.com/rust-lang/rust/issues/124225
2025-06-24Update tidy exceptionsbjorn3-0/+3
2025-06-24Move some `issues-*` tests to better homesTrevor Gross-3/+1
These tests were updated in the previous commit; while they are being cleaned up, move them to a non-issue directory.
2025-06-23Move error code explanation removal check into tidyGuillaume Gomez-2/+32
2025-06-23Create new `CiInfo` type in tidy checks to centralize CI related checksGuillaume Gomez-44/+71
2025-06-23Rollup merge of #142875 - GuillaumeGomez:rustdoc-json-types-version-update, ↵Matthias Krüger-0/+25
r=Kobzol Check rustdoc-json-types FORMAT_VERSION is correctly updated Follow-up of https://github.com/rust-lang/rust/pull/142677. ``@nnethercote`` suggested that we should also ensure that the `FORMAT_VERSION` was only increased by 1 and we should check for it, this PR does it. cc ``@aDotInTheVoid`` r? ghost
2025-06-22Document why tidy checks if `eslint` is installed via `npm`Yotam Ofek-0/+3
2025-06-22Check rustdoc-json-types FORMAT_VERSION correct changeGuillaume Gomez-0/+25
2025-06-20Rollup merge of #142677 - GuillaumeGomez:check-format-version-update, r=KobzolTrevor Gross-0/+103
Add CI check to ensure that rustdoc JSON `FORMAT_VERSION` is correctly updated Follow-up of https://github.com/rust-lang/rust/pull/142601. Tested it locally with: `BASE_COMMIT=1bb335244c311a07cee165c28c553c869e6f64a9 src/ci/docker/host-x86_64/mingw-check-1/validate-rustdoc-json-format-version-update.sh` (where `BASE_COMMIT` value was the commit before I made a wrong change with the `FORMAT_VERSION` update). This is a first version. I plan to send a follow-up to also ensure that `FORMAT_VERSION` is updated if any code change is done in `rustdoc-json-types`. For that I just need to check that a line not starting with `/` and not an empty line was updated. Fun times with `grep` ahead. :') cc `@aDotInTheVoid` r? `@nnethercote`
2025-06-20Rollup merge of #142384 - celinval:chores-rayon-mv, r=oli-obkTrevor Gross-1/+1
Bringing `rustc_rayon_core` in tree as `rustc_thread_pool` This PR moves [`rustc_rayon_core`](https://github.com/rust-lang/rustc-rayon/tree/5fadf44/rayon-core) from commit `5fadf44` as suggested in [this zulip thread](https://rust-lang.zulipchat.com/#narrow/channel/187679-t-compiler.2Fparallel-rustc/topic/Bringing.20.60rustc_rayon_core.60.20in.20tree). I tried to split the work into separate commits so it is easy to review. The first commit is a simple copy and paste from the fork, and subsequent changes were made to use the new crate and to ensure the new crate complies with different format and lint expectations. **Call-out:** I was also wondering if I need to make any further changes to accommodate licensing requirements. r? oli-obk
2025-06-20Improve error message for rustdoc_json_types tidy checkGuillaume Gomez-10/+20
Only emit git errors if we are in CI environment
2025-06-20Pass `src_path` to rustdoc_json tidy checkGuillaume Gomez-11/+13
2025-06-20Generate base commit in rustdoc_json tidy checksGuillaume Gomez-4/+27
2025-06-20Add CI check to ensure that rustdoc JSON `FORMAT_VERSION` is correctly updatedGuillaume Gomez-0/+68
2025-06-19Auto merge of #140748 - m-ou-se:super-format-args3, r=jdonszelmannbors-1/+0
Allow storing `format_args!()` in variable Fixes https://github.com/rust-lang/rust/issues/92698 Tracking issue for super let: https://github.com/rust-lang/rust/issues/139076 Tracking issue for format_args: https://github.com/rust-lang/rust/issues/99012 This change allows: ```rust let name = "world"; let f = format_args!("hello {name}!"); // New: Store format_args!() for later! println!("{f}"); ``` This will need an FCP. This implementation makes use of `super let`, which is unstable and might not exist in the future in its current form. However, it is entirely reasonable to assume future Rust will always have _a_ way of expressing temporary lifetimes like this, since the (stable) `pin!()` macro needs this too. (This was also the motivation for merging https://github.com/rust-lang/rust/pull/139114.) (This is a second version of https://github.com/rust-lang/rust/pull/139135)
2025-06-18Skip tidy triagebot linkcheck if `triagebot.toml` doesn't existJieyou Xu-1/+4
2025-06-18Remove outdated test.Mara Bos-1/+0
We no longer error in this case!
2025-06-13Update tests.Mara Bos-1/+0
2025-06-11Add new permitted dependenciesMark Rousskov-0/+1
2025-06-11Use `rustc_thread_pool` instead of `rustc-rayon-core`Celina G. Val-1/+1
2025-06-03Auto merge of #141229 - tgross35:builtins-josh-subtree, r=Kobzolbors-0/+2
Merge `compiler-builtins` as a Josh subtree Use the Josh [1] utility to add `compiler-builtins` as a subtree, which will allow us to stop using crates.io for updates. This is intended to help resolve some problems when unstable features change and require code changes in `compiler-builtins`, which sometimes gets trapped in a bootstrap cycle. This was done using `josh-filter` built from the r24.10.04 tag: git fetch https://github.com/rust-lang/compiler-builtins.git 233434412fe7eced8f1ddbfeddabef1d55e493bd josh-filter ":prefix=library/compiler-builtins" FETCH_HEAD git merge --allow-unrelated FILTERED_HEAD The HEAD in the `compiler-builtins` repository is 233434412f ("fix an if statement that can be collapsed"). [1]: https://github.com/josh-project/josh
2025-06-03move `test-float-parse` tool into `src/tools` dironur-ozkan-1/+1
Obviously `test-float-parse` is a tool like any other in `src/tools`. Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-05-29Rollup merge of #141705 - GuillaumeGomez:eslint-tidy, r=KobzolGuillaume Gomez-0/+102
Add eslint as part of `tidy` run Rustdoc uses `eslint` to run lints on the JS files. Currently you need to run it by hand since it's not part of any `x.py` command. This PR makes it part of `test tidy`. However, to prevent having all rust developers to install `npm` and `eslint`, I made it optional: if `eslint` is not installed, then the check is simply skipped (but will tell that it is being skipped). The second commit removes the manual checks from the docker file since `eslint` is run as part of tidy. cc `@lolbinarycat,` [#t-rustdoc > eslint seems to only be run in CI](https://rust-lang.zulipchat.com/#narrow/channel/266220-t-rustdoc/topic/eslint.20seems.20to.20only.20be.20run.20in.20CI/with/520761477)
2025-05-29Centralize the eslint version between tidy and dockerGuillaume Gomez-8/+16
2025-05-28Add `eslint` as part of tidy runGuillaume Gomez-0/+94
2025-05-28tidy: Skip pal and `#[test]` checks in compiler-builtinsTrevor Gross-0/+2
2025-05-28Stabilise `repr128`beetrees-1/+0
2025-05-27bump fluent-* cratesklensy-1/+1
2025-05-25Update tidy exceptionsbjorn3-0/+2
2025-05-25feat(unstable-book): Added unstable feature doc comments as feature descriptionsRoss Sullivan-0/+17
2025-05-17compiler & tools: bump windows crate to dedupe versionsklensy-0/+3
2025-05-16Rollup merge of #140834 - lcnr:apit-folder, r=compiler-errorsMatthias Krüger-30/+30
move (or remove) some impl Trait tests Probably not actually worth the effort, so I am stopping here :sweat_smile:
2025-05-12Move more tests/ui testsmejrs-2/+1
2025-05-09move (and remove) impl Trait testslcnr-30/+30
2025-05-05Auto merge of #140353 - rust-lang:cargo_update, r=Mark-Simulacrumbors-7/+3
Weekly `cargo update` Automation to keep dependencies in `Cargo.lock` current. The following is the output from `cargo update`: ```txt compiler & tools dependencies: Locking 36 packages to latest compatible versions Updating addr2line v0.21.0 -> v0.24.2 Updating anyhow v1.0.97 -> v1.0.98 Updating askama v0.13.0 -> v0.13.1 (available: v0.14.0) Updating askama_derive v0.13.0 -> v0.13.1 Updating backtrace v0.3.71 -> v0.3.74 Updating blake3 v1.8.1 -> v1.8.2 Updating chrono v0.4.40 -> v0.4.41 Updating clap v4.5.36 -> v4.5.37 Updating clap_builder v4.5.36 -> v4.5.37 Updating color-eyre v0.6.3 -> v0.6.4 Updating color-spantrace v0.2.1 -> v0.2.2 Updating derive-where v1.2.7 -> v1.4.0 Updating getrandom v0.2.15 -> v0.2.16 Removing gimli v0.28.1 Updating hashbrown v0.15.2 -> v0.15.3 Updating jiff v0.2.6 -> v0.2.12 Updating jiff-static v0.2.6 -> v0.2.12 Updating libm v0.2.11 -> v0.2.13 Removing object v0.32.2 Updating openssl-sys v0.9.107 -> v0.9.108 Adding owo-colors v4.2.0 Updating proc-macro2 v1.0.94 -> v1.0.95 Updating psm v0.1.25 -> v0.1.26 Updating rand v0.9.0 -> v0.9.1 Updating redox_syscall v0.5.11 -> v0.5.12 Updating rustix v1.0.5 -> v1.0.7 Updating sha2 v0.10.8 -> v0.10.9 Updating stacker v0.1.20 -> v0.1.21 Updating syn v2.0.100 -> v2.0.101 Updating synstructure v0.13.1 -> v0.13.2 Updating toml_datetime v0.6.8 -> v0.6.9 Adding windows v0.61.1 Adding windows-collections v0.2.0 Adding windows-future v0.2.0 Adding windows-numerics v0.2.0 Updating winnow v0.7.6 -> v0.7.9 Updating zerocopy v0.8.24 -> v0.8.25 Updating zerocopy-derive v0.8.24 -> v0.8.25 note: pass `--verbose` to see 33 unchanged dependencies behind latest library dependencies: Locking 2 packages to latest compatible versions Removing allocator-api2 v0.2.21 Updating hashbrown v0.15.2 -> v0.15.3 Removing proc-macro2 v1.0.94 Removing quote v1.0.40 Updating rand v0.9.0 -> v0.9.1 Removing syn v2.0.100 Removing unicode-ident v1.0.18 Removing zerocopy v0.8.24 Removing zerocopy-derive v0.8.24 note: pass `--verbose` to see 3 unchanged dependencies behind latest rustbook dependencies: Locking 31 packages to latest compatible versions Updating ammonia v4.0.0 -> v4.1.0 Updating anyhow v1.0.97 -> v1.0.98 Updating cc v1.2.19 -> v1.2.21 Updating chrono v0.4.40 -> v0.4.41 Updating clap v4.5.36 -> v4.5.37 Updating clap_builder v4.5.36 -> v4.5.37 Updating clap_complete v4.5.47 -> v4.5.48 Adding cssparser v0.35.0 Adding cssparser-macros v0.6.1 Adding dtoa v1.0.10 Adding dtoa-short v0.3.5 Updating hashbrown v0.15.2 -> v0.15.3 Updating html5ever v0.27.0 -> v0.31.0 Updating jiff v0.2.6 -> v0.2.12 Updating jiff-static v0.2.6 -> v0.2.12 Updating libc v0.2.171 -> v0.2.172 Updating markup5ever v0.12.1 -> v0.16.1 Adding match_token v0.1.0 Adding phf_macros v0.11.3 Updating proc-macro2 v1.0.94 -> v1.0.95 Updating redox_syscall v0.5.11 -> v0.5.12 Updating rustix v1.0.5 -> v1.0.7 Updating sha2 v0.10.8 -> v0.10.9 Updating syn v2.0.100 -> v2.0.101 Updating synstructure v0.13.1 -> v0.13.2 Updating toml v0.8.20 -> v0.8.22 Updating toml_datetime v0.6.8 -> v0.6.9 Updating toml_edit v0.22.24 -> v0.22.26 Adding toml_write v0.1.1 Adding web_atoms v0.1.1 Updating winnow v0.7.6 -> v0.7.9 ```
2025-05-04Fix tidy dep listMark Rousskov-7/+3
2025-05-03Move some tests out of tests/uimejrs-10/+0
2025-04-30Rollup merge of #140385 - lnicola:sync-from-ra, r=VeykrilMatthias Krüger-0/+1
Subtree update of `rust-analyzer` r? ````@ghost````
2025-04-29Coalesce duplicate missing clone testsmejrs-2/+1
2025-04-28Add foldhash license exceptionLaurențiu Nicola-0/+1
2025-04-25Add a tidy check for GCC submodule versionJakub Beránek-0/+49
2025-04-19Rollup merge of #139995 - spencer3035:clean-ui-tests-4-of-n, r=jieyouxuChris Denton-6/+1
Clean UI tests 4 of n Cleaned up some tests that have `issue` in the title. I kept the commits to be one per "`issue`" cleanup/rename to make it easier to check. I can rebase to one commit once the changes are approved. Related Issues: #73494 #133895 r? jieyouxu
2025-04-19Rollup merge of #139091 - mejrs:format, r=compiler-errorsChris Denton-1/+0
Rewrite on_unimplemented format string parser. This PR rewrites the format string parser for `rustc_on_unimplemented` and `diagnostic::on_unimplemented`. I plan on moving this code (and more) into the new attribute parsing system soon and wanted to PR it separately. This PR introduces some minor differences though: - `rustc_on_unimplemented` on trait *implementations* is no longer checked/used - this is actually never used (outside of some tests) so I plan on removing it in the future. - for `rustc_on_unimplemented`, it introduces the `{This}` argument in favor of `{ThisTraitname}` (to be removed later). It'll be easier to parse. - for `rustc_on_unimplemented`, `Self` can now consistently be used as a filter, rather than just `_Self`. It used to not match correctly on for example `Self = "[{integer}]"` - Some error messages now have better spans. Fixes https://github.com/rust-lang/rust/issues/130627
2025-04-19Cleaned up 4 tests in `tests/ui/issues`Spencer-6/+1
2025-04-17Rollup merge of #139935 - cuviper:rustc-rayon-core-0.5.1, r=lqdMatthias Krüger-3/+0
Upgrade to `rustc-rayon-core` 0.5.1 * [Fix a race with deadlock detection](https://github.com/rust-lang/rustc-rayon/pull/15) * [Cherry-pick changes from upstream rayon-core](https://github.com/rust-lang/rustc-rayon/pull/16) - This also removes a few dependencies from rustc's tidy list.