about summary refs log tree commit diff
path: root/src/tools
AgeCommit message (Collapse)AuthorLines
2024-07-28Merge from rust-lang/rustLaurențiu Nicola-6551/+8321
2024-07-28Preparing for merge from rust-lang/rustLaurențiu Nicola-1/+1
2024-07-28Rollup merge of #128215 - ehuss:update-reference, r=KobzolMatthias Krüger-1/+35
Update the reference This updates the reference to use the new mdbook-spec preprocessor, which is a Cargo library inside the reference submodule. Note that this PR contains a bunch of bootstrap cleanup commits to assist with making sure the submodules are working correctly. All of the cleanup PRs should have a description in their commit. I'd be happy to move those to a separate PR if that makes review easier. The main changes for the reference are: - Move the `doc::Reference` bootstrap step out of the generic macro into a custom step. - This step needs to build rustdoc because the new mdbook-spec plugin uses rustdoc for generating links. - PATH is updated so that the rustdoc binary can be found. - rustbook now includes the mdbook-spec plugin as a dependency. - rustbook enables the mdbook-spec preprocessor. I did a bunch of testing with the various commands and setups, such as: - `submodules=true` and `submodules=false` - having all submodules deinitialized - not in a git repository However, there are probably thousands of different permutations of different commands, settings, and environments, so there is a chance I'm missing something.
2024-07-28Auto merge of #17720 - ThouCheese:fix/doc-to-comment-naming, r=Veykrilbors-2/+2
flip the naming of the doc comment to comment assist I did this the wrong way around when I implemented these assists, so here is a quick fix for it
2024-07-28Rollup merge of #128279 - slanterns:is_sorted, r=dtolnayMatthias Krüger-9/+6
Stabilize `is_sorted` Closes: https://github.com/rust-lang/rust/issues/53485. ~~Question: does~~ https://github.com/rust-lang/rust/blob/8fe0c753f23e7050b87a444b6622caf4d2272d5d/compiler/rustc_lint_defs/src/builtin.rs#L1986-L1994 ~~need a new example?~~ edit: It causes a test failure and needs to be changed anyway. ``@rustbot`` label: +T-libs-api r? libs-api
2024-07-28Rollup merge of #128276 - ehuss:rustbook-readme, r=KobzolMatthias Krüger-0/+34
Add a README to rustbook to explain its purpose This adds a README to the rustbook tool to help explain what it is for and how to use it.
2024-07-2817470 - run test explorer tests at the package level and add missing ↵duncan-10/+54
extra_test_bin_args settings
2024-07-28Determine toolchain RA on agehuntc-16/+196
Selects a rust-toolchain declared RA based on its date. The earliest (oldest) RA wins and becomes the one that the workspace uses as a whole. In terms of precedence: nightly > stable-with-version > stable With stable-with-version, we invoke the RA with a `--version` arg and attempt to extract a date. Given the same date as a nightly, the nightly RA will win.
2024-07-27feat: add trace level to client logsJosh McKinney-0/+4
2024-07-27feat: use vscode log format for client logsJosh McKinney-46/+44
This change updates the log format to use the vscode log format instead of the custom log format, by replacing the `OutputChannel` with a `LogOutputChannel` and using the `debug`, `info`, `warn`, and `error` methods on it. This has the following benefits: - Each log level now has its own color and the timestamp is in a more standard format - Inspect output (e.g. the log of the config object) is now colored - Error stack traces are now shown in the output - The log level is now controlled on the output tab by clicking the gear icon and selecting "Debug" or by passing the `--log` parameter to vscode. The `trace.extension` setting has been marked as deprecated.
2024-07-28Auto merge of #128079 - Oneirical:testiges-of-civilization, r=jieyouxubors-4/+0
Migrate `static-dylib-by-default`, `sanitizer-dylib-link`, `sanitizer-cdylib-link` and `sanitizer-staticlib-link` `run-make` tests to rmake Part of #121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html). Please try: try-job: x86_64-msvc try-job: armhf-gnu try-job: test-various try-job: i686-msvc try-job: x86_64-mingw try-job: x86_64-gnu-llvm-18
2024-07-27Auto merge of #128270 - weihanglo:update-cargo, r=weihanglobors-0/+0
Update cargo 14 commits in 5f6b9a92201d78af75dc24f14662c3e2dacbbbe1..b5d44db1daf0469b227a6211b987162a39a54730 2024-07-19 18:09:17 +0000 to 2024-07-26 21:27:12 +0000 - Package workspaces (rust-lang/cargo#13947) - test: migrate messages to snapbox (rust-lang/cargo#14242) - chore: Update dependencies (rust-lang/cargo#14299) - fix: remove rustc probe for `--check-cfg` support (rust-lang/cargo#14302) - Misc test clean up (rust-lang/cargo#14297) - Don't downgrade on prerelease `VersionReq` when update with --breaking. (rust-lang/cargo#14250) - test: Migrate some json tests to snapbox (rust-lang/cargo#14293) - Revert "fix: Ensure dep/feature activates the dependency on 2024" (rust-lang/cargo#14295) - chore: bump cargo-test-support to 0.4.0 (rust-lang/cargo#14286) - Bump to 0.83.0; update changelog (rust-lang/cargo#14285) - Improved error message when `update --breaking` invalid spec. (rust-lang/cargo#14279) - docs(test): Expand documentation of cargo-test-support (rust-lang/cargo#14272) - test: Fix some test based on rustc version (rust-lang/cargo#14282) - Use `Rc` instead of `Arc` for storing rustflags (rust-lang/cargo#14273) r? ghost
2024-07-28flip the naming of the doc comment to comment assistLuuk Wester-2/+2
2024-07-27Down to 1 failing testAli Bektas-80/+66
And that is due to a case where we have two ratomls in a source root, one of which is a `workspace_ratoml` and the other one is simple old ratoml. Since we are not checking to see if the source root is already populated with workspace ratoml, this test fails. Due to principles of clear code I believe it is reasonable to not have two HashMaps that are almost for the exact same thing. So next commit should remove `workspace_ratoml` and merge it with `krate_ratoml`s.
2024-07-27improve dangling/oob errors and make them more uniformRalf Jung-84/+86
2024-07-28stabilize `is_sorted`Slanterns-9/+6
2024-07-28Fix for #17497 - Invalid RA diagnostic error: expected 2 arguments, found 1Francis McKenzie-3/+47
The issue occurs because in some configurations of traits where one of them has Deref as a supertrait, RA's type inference algorithm fails to resolve the Deref::Target type, and instead uses a TyKind::BoundVar (i.e. an unknown type). This "autoderefed" type then incorrectly acts as if it implements all traits in scope. The fix is to re-apply the same sanity-check that is done in iterate_method_candidates_with_autoref(), that is: don't try to resolve methods on unknown types. This same sanity-check is now done on each autoderefed type for which trait methods are about to be checked. If the autoderefed type is unknown, then the iterating of the trait methods for that type is skipped. Includes a unit test that only passes after applying the fixes in this commit. Includes a change to the assertion count in test syntax_highlighting::tests::benchmark_syntax_highlighting_parser as suggested by Lukas Wirth during review. Includes a change to the sanity-check code as suggested by Florian Diebold during review.
2024-07-27Auto merge of #128091 - heiher:xz-only, r=Mark-Simulacrumbors-1/+1
build-manifest: Allow building manifests for formats that only have xz compression
2024-07-27Add a README to rustbook to explain its purposeEric Huss-0/+34
2024-07-27miri: fix offset_from behavior on wildcard pointersRalf Jung-6/+16
2024-07-27Update cargoWeihang Lo-0/+0
2024-07-27fix clippyRalf Jung-1/+1
2024-07-27Merge from rustcThe Miri Cronjob Bot-5195/+4899
2024-07-27Preparing for merge from rustcThe Miri Cronjob Bot-1/+1
2024-07-27Auto merge of #17714 - Throne3d:patch-1, r=Veykrilbors-1/+1
docs: Reference cov_mark crate instead of test_utils/mark Seems this was switched over in https://github.com/rust-lang/rust-analyzer/issues/7922 I'm guessing this should skip the changelog because it's so minor, right? Reading through https://github.com/rust-lang/rust-analyzer/blob/master/docs/dev/style.md and trying to get up to speed here =)
2024-07-27fix: let glob imports override other globs' visibilityRyo Yoshida-32/+197
2024-07-26docs: Reference cov_mark crate instead of test_utils/markEdward Jones-1/+1
Seems this was switched over in https://github.com/rust-lang/rust-analyzer/issues/7922
2024-07-26Rollup merge of #124941 - Skgland:stabilize-const-int-from-str, r=dtolnayTrevor Gross-12/+12
Stabilize const `{integer}::from_str_radix` i.e. `const_int_from_str` This PR stabilizes the feature `const_int_from_str`. - ACP Issue: rust-lang/libs-team#74 - Implementation PR: rust-lang/rust#99322 - Part of Tracking Issue: rust-lang/rust#59133 API Change Diff: ```diff impl {integer} { - pub fn from_str_radix(src: &str, radix: u32) -> Result<Self, ParseIntError>; + pub const fn from_str_radix(src: &str, radix: u32) -> Result<Self, ParseIntError>; } impl ParseIntError { - pub fn kind(&self) -> &IntErrorKind; + pub const fn kind(&self) -> &IntErrorKind; } ``` This makes it easier to parse integers at compile-time, e.g. the example from the Tracking Issue: ```rust env!("SOMETHING").parse::<usize>().unwrap() ``` could now be achived with ```rust match usize::from_str_radix(env!("SOMETHING"), 10) { Ok(val) => val, Err(err) => panic!("Invalid value for SOMETHING environment variable."), } ``` rather than having to depend on a library that implements or manually implement the parsing at compile-time. --- Checklist based on [Libs Stabilization Guide - When there's const involved](https://std-dev-guide.rust-lang.org/development/stabilization.html#when-theres-const-involved) I am treating this as a [partial stabilization](https://std-dev-guide.rust-lang.org/development/stabilization.html#partial-stabilizations) as it shares a tracking issue (and is rather small), so directly opening the partial stabilization PR for the subset (feature `const_int_from_str`) being stabilized. - [x] ping Constant Evaluation WG - [x] no unsafe involved - [x] no `#[allow_internal_unstable]` - [ ] usage of `intrinsic::const_eval_select` rust-lang/rust#124625 in `from_str_radix_assert` to change the error message between compile-time and run-time - [ ] [rust-labg/libs-api FCP](https://github.com/rust-lang/rust/pull/124941#issuecomment-2207021921)
2024-07-26early exit if unresolved field is an indexAli Bektas-3/+45
2024-07-26Auto merge of #121676 - Bryanskiy:polarity, r=petrochenkovbors-12/+16
Support ?Trait bounds in supertraits and dyn Trait under a feature gate This patch allows `maybe` polarity bounds under a feature gate. The only language change here is that corresponding hard errors are replaced by feature gates. Example: ```rust #![feature(allow_maybe_polarity)] ... trait Trait1 : ?Trait { ... } // ok fn foo(_: Box<(dyn Trait2 + ?Trait)>) {} // ok fn bar<T: ?Sized + ?Trait>(_: &T) {} // ok ``` Maybe bounds still don't do anything (except for `Sized` trait), however this patch will allow us to [experiment with default auto traits](https://github.com/rust-lang/rust/pull/120706#issuecomment-1934006762). This is a part of the [MCP: Low level components for async drop](https://github.com/rust-lang/compiler-team/issues/727)
2024-07-26assert_stdout_contains_regex in run_make_support + variationsOneirical-5/+97
2024-07-26Rewrite and rename issue-35164 to rmakeOneirical-2/+1
2024-07-26rewrite and rename issue-47551 to rmakeOneirical-1/+0
2024-07-26Add `flock` shimАртём Павлов [Artyom Pavlov]-2/+230
2024-07-26rewrite no-builtins-attribute to rmakeOneirical-1/+0
2024-07-26rewrite native-link-modifier-whole-archive to rmakeOneirical-1/+0
2024-07-26rewrite rlib-format-packed-bundled-libs-2 to rmakeOneirical-1/+0
2024-07-26rewrite sanitizer-staticlib-link to rmakeOneirical-1/+0
2024-07-26fix: tweak hover/tooltip linksYoung-Flash-6/+11
2024-07-26rewrite export-executable-symbols to rmakeOneirical-1/+0
2024-07-26rewrite foreign-rust-exceptions to rmakeOneirical-1/+0
2024-07-26rewrite c-unwind-abi-catch-lib-panic to rmakeOneirical-1/+0
2024-07-26Auto merge of #3763 - tiif:global-fd-id, r=oli-obkbors-34/+24
Insert FileDescription instead of FileDescriptor in ``insert_fd`` This PR moves the creation of ``FileDescriptor`` inside ``insert_fd``, and ``insert_fd`` now takes in ``FileDescription`` instead of ``FileDescriptor``. This change is needed by #3712.
2024-07-26Let insert_fd takes in FileDescription instead of FileDescriptortiif-34/+24
2024-07-26Auto merge of #3766 - RalfJung:tree-borrows-int2ptr, r=RalfJungbors-138/+201
better diagnostics for Tree Borrows + int2ptr casts - Entirely reject `-Zmiri-permissive-provenance -Zmiri-tree-borrows` since that combination just doesn't work - In the int2ptr cast warning, when Tree Borrows is enabled, do not recommend `-Zmiri-permissive-provenance`, instead note that Tree Borrows does not support int2ptr casts Fixes https://github.com/rust-lang/miri/issues/3764
2024-07-26diagnostics: add a macro to make things a bit easier to readRalf Jung-76/+59
2024-07-26better diagnostics for Tree Borrows + int2ptr castsRalf Jung-70/+150
2024-07-26Internal: Cleanup proc-macro error handlingLukas Wirth-522/+380
2024-07-26fix: Fix includes not working with expr fragment inputsLukas Wirth-3/+18
2024-07-26Rollup merge of #128099 - lolbinarycat:extern-flag-disambiguates-rmake, r=KobzolTrevor Gross-1/+0
migrate tests/run-make/extern-flag-disambiguates to rmake