about summary refs log tree commit diff
path: root/src/tools
AgeCommit message (Collapse)AuthorLines
2025-06-11hir-ty: test (the absence of) incremental trait solvingDavid Barsky-1/+87
2025-06-11stabilize gaiBoxy-11/+10
2025-06-11Rollup merge of #142297 - jieyouxu:needs-target-std, r=KobzolMatthias Krüger-0/+17
Implement `//@ needs-target-std` compiletest directive Closes rust-lang/rust#141863. Needed to unblock rust-lang/rust#139244 and rust-lang/rust#141856. ### Summary This PR implements a `//@ needs-target-std` compiletest directive that gates test execution based on whether the target supports std or not. For some cases, this should be preferred over e.g. some combination of `//@ ignore-none`, `//@ ignore-nvptx` and more[^none-limit]. ### Implementation limitation Unfortunately, since there is currently [no reliable way to determine from metadata whether a given target supports std or not](https://github.com/rust-lang/rust/issues/142296), we have to resort to a hack. Bootstrap currently determines whether or not a target supports std by a naive target tuple substring comparison: a target supports std if its target tuple does *not* contain one of `["-none", "nvptx", "switch"]` substrings. This PR simply pulls that hack out into `build_helpers` to avoid reimplementing the same hack in compiletest, and uses that logic to inform `//@ needs-target-std`. ### Auxiliary changes This PR additionally changes a few run-make tests to use `//@ needs-target-std` over an inconsistent combination of target-based `ignore`s. This should help with rust-lang/rust#139244. --- r? bootstrap [^none-limit]: Notably, `target_os = "none"` is **not** a sufficient condition for "target does not support std"
2025-06-11Merge pull request #19973 from Veykril/push-ppltxvqvqmkkLukas Wirth-3/+9
fix: Hide dyn inlay hints for incomplete `impl`s
2025-06-11fix: Hide dyn inlay hints for incomplete `impl`sLukas Wirth-3/+9
2025-06-11Merge pull request #4384 from RalfJung/diag-no-repeatOli Scherer-874/+727
diagnostics: do not repeat the entire message in the span label
2025-06-11miri: we can use apfloat's mul_add nowRalf Jung-10/+6
2025-06-11miri: add flag to suppress float non-determinismRalf Jung-4/+31
2025-06-11Fix proc macro server handling of strings with minusesChayim Refael Friedman-31/+26
It used to decompose them thinking they were numbers.
2025-06-10Auto merge of #142292 - RalfJung:miri-sync, r=RalfJungbors-228/+420
Miri subtree update r? `@ghost`
2025-06-10Implement `//@ needs-target-std` directive in compiletestJieyou Xu-0/+17
To support tests to condition their (potentially cross-compile) execution based on whether the target supports std.
2025-06-10Merge pull request #19964 from Wilfred/fix_typosChayim Refael Friedman-2/+2
[minor] Fix typos
2025-06-10[minor] Fix typosWilfred Hughes-2/+2
2025-06-10Merge pull request #19963 from ChayimFriedman2/unsized-impl-itemsLukas Wirth-3/+64
fix: Do not error at impls for unsized types that do not include `where Self: Sized` items
2025-06-10Do not error at impls for unsized types that do not include `where Self: ↵Chayim Refael Friedman-3/+64
Sized` items
2025-06-10Merge pull request #4389 from RalfJung/native-lib-search-orderRalf Jung-22/+25
native_lib: skip to next .so if function was in dependency of the first
2025-06-10Merge pull request #4382 from RalfJung/dupRalf Jung-2/+3
test_dup: ensure the FDs remain in sync even after dup'ing
2025-06-10Add jemalloc feature to ClippyJakub Beránek-0/+36
2025-06-10float tests: test non-determinism for more operationsRalf Jung-22/+25
2025-06-10Merge pull request #4394 from RalfJung/smallvecRalf Jung-0/+99
add SmallVec test
2025-06-10add SmallVec testRalf Jung-0/+99
2025-06-10sync max_fundamental_align with alloc crateRalf Jung-4/+7
2025-06-10Auto merge of #142109 - weihanglo:update-cargo, r=weihanglobors-0/+0
Update cargo 18 commits in 64a12460708cf146e16cc61f28aba5dc2463bbb4..fc1518ef02b77327d70d4026b95ea719dd9b8c51 2025-05-30 18:25:08 +0000 to 2025-06-06 04:49:44 +0000 - fix: Make UI tests handle hyperlinks consistently (rust-lang/cargo#15640) - Update "time out" to "timeout" (rust-lang/cargo#15637) - fix(workspace): reload current manifest path member only (rust-lang/cargo#15633) - Update dependencies (rust-lang/cargo#15635) - fix(publish): Don't tell people to ctrl-c without knowing consequences (rust-lang/cargo#15632) - refactor: clean up `clippy::perf` lint warnings (rust-lang/cargo#15631) - fix(package): Skip registry check if its not needed (rust-lang/cargo#15629) - Add --offline for comp (rust-lang/cargo#15623) - cargo-credential-libsecret: load libsecret only once (rust-lang/cargo#15295) - test(publish): Improvements in prep for `-Zpackage-workspace` stabilization (rust-lang/cargo#15628) - fix(package): Allow packaging of self-cycles with -Zpackage-workspace (rust-lang/cargo#15626) - docs: clarify `--all-features` not available for all commmands (rust-lang/cargo#15572) - Remove double reference in Shell::print_json (rust-lang/cargo#15460) - fix(trim-paths): remap all paths to `build.build-dir` (rust-lang/cargo#15614) - test(trim-paths): enable more tests for windows-msvc (rust-lang/cargo#15621) - fix(fingerprint): explicit reason rather than "stale; unknown reason" (rust-lang/cargo#15617) - Fix cargo add overwriting symlinked Cargo.toml files (rust-lang/cargo#15281) - chore(deps): update alpine docker tag to v3.22 (rust-lang/cargo#15616) r? ghost
2025-06-10fmtThe Miri Cronjob Bot-1/+0
2025-06-10Merge from rustcThe Miri Cronjob Bot-67/+379
2025-06-10Preparing for merge from rustcThe Miri Cronjob Bot-1/+1
2025-06-10Auto merge of #142250 - lnicola:sync-from-ra, r=lnicolabors-1085/+2373
Subtree update of `rust-analyzer` r? `@ghost`
2025-06-09Auto merge of #138062 - LorrensP-2158466:miri-enable-float-nondet, r=RalfJungbors-62/+329
Enable Non-determinism of float operations in Miri and change std tests Links to [#4208](https://github.com/rust-lang/miri/issues/4208) and [#3555](https://github.com/rust-lang/miri/issues/3555) in Miri. Non-determinism of floating point operations was disabled in rust-lang/rust#137594 because it breaks the tests and doc-tests in core/coretests and std. This PR enables some of them. This pr includes the following changes: - Enables the float non-determinism but with a lower relative error of 4ULP instead of 16ULP - These operations now have a fixed output based on the C23 standard, except the pow operations, this is tracked in [#4286](https://github.com/rust-lang/miri/issues/4286#issue-3010677983) - Changes tests that made incorrect assumptions about the operations, not to make that assumption anymore (from `assert_eq!` to `assert_approx_eq!`. - Changed the doctests of the stdlib of these operations to compare against fixed constants instead of `f*::EPSILON`, which now succeed with Miri and `-Zmiri-many-seeds` - Added a constant `APPROX_DELTA` in `std/tests/floats/f32.rs` which is used for approximation tests, but with a different value when run in Miri. This is to make these tests succeed. - Added tests in the float tests of Miri to test the C23 behaviour. Fixes https://github.com/rust-lang/miri/issues/4208
2025-06-09native-lib: update readme (to mention folders in header)Ralf Jung-10/+12
2025-06-09native_lib: skip to next .so if function was in dependency of the firstRalf Jung-12/+13
2025-06-09Merge pull request #19930 from regexident/dyn-semantics-take-twoDavid Barsky-2/+18
Make `Semantics<'db, DB>` support `Semantics<'db, dyn HirDatabase>`, take two
2025-06-09Rollup merge of #141993 - tgross35:use-in-tree-builtins, r=bjorn3Trevor Gross-3/+42
Use the in-tree `compiler-builtins` for the sysroot Many of `std`'s dependency have a dependency on the crates.io `compiler-builtins` when used with the feature `rustc-std-workspace-core`. Use a Cargo patch to select the in-tree version instead. `compiler-builtins` is also added as a dependency of `rustc-std-workspace-core` so these crates can remove their crates.io dependency in the future. Zulip discussion: [#t-compiler > Using in-tree compiler-builtins](https://rust-lang.zulipchat.com/#narrow/channel/131828-t-compiler/topic/Using.20in-tree.20compiler-builtins/with/522445336) Once this merges, the following PRs will need to make it to a release for the relevant crates: - https://github.com/rust-lang/getopts/pull/119 (can merge at any time) - https://github.com/rust-lang/hashbrown/pull/625 (can merge at any time) - https://github.com/rust-lang/stdarch/pull/1825 - https://github.com/rust-lang/rustc-demangle/pull/80 - https://github.com/rust-lang/cfg-if/pull/84 - https://github.com/unicode-rs/unicode-width/pull/77 The above should cover all tier 1 targets with no `std` features enabled. The remaining cover the rest: - https://github.com/alexcrichton/dlmalloc-rs/pull/50 (wasm, xous, sgx) - https://github.com/gimli-rs/gimli/pull/769 - https://github.com/r-efi/r-efi/pull/89 (efi) - https://github.com/r-efi/r-efi-alloc/pull/9 (efi) - https://github.com/fortanix/rust-sgx/pull/770 (sgx) - https://github.com/hermit-os/hermit-rs/pull/718 (hermit) - https://github.com/bytecodealliance/wasi-rs/pull/108 (wasi) - https://github.com/gimli-rs/addr2line/pull/345 - https://github.com/oyvindln/adler2/pull/2 - https://github.com/BurntSushi/memchr/pull/180 - https://github.com/Frommi/miniz_oxide/pull/173 - https://github.com/gimli-rs/object/pull/777 try-job: x86_64-gnu try-job: test-various
2025-06-09Merge pull request #4376 from yoctocell/tb-interior-mut-flagRalf Jung-35/+154
TB: Add flag to disable the more precise interior mutability tracking
2025-06-09Add `-Zmiri-tree-borrows-no-precise-interior-mut` flagXinglu Chen-35/+154
2025-06-09Merge from rust-lang/rustLaurențiu Nicola-6726/+13901
2025-06-09Preparing for merge from rust-lang/rustLaurențiu Nicola-1/+1
2025-06-09Merge from rustcThe Miri Cronjob Bot-67/+90
2025-06-09Preparing for merge from rustcThe Miri Cronjob Bot-1/+1
2025-06-09Auto merge of #142220 - workingjubilee:rollup-idgfpof, r=workingjubileebors-2/+8
Rollup of 12 pull requests Successful merges: - rust-lang/rust#141803 (Remove rustc's notion of "preferred" alignment AKA `__alignof`) - rust-lang/rust#142053 (Add new Tier-3 targets: `loongarch32-unknown-none*`) - rust-lang/rust#142089 (Replace all uses of sysroot_candidates with get_or_default_sysroot) - rust-lang/rust#142108 (compiler: Add track_caller to AbiMapping::unwrap) - rust-lang/rust#142132 (`tests/ui`: A New Order [6/N]) - rust-lang/rust#142162 (UnsafePinned: update get() docs and signature to allow shared mutation) - rust-lang/rust#142171 (`tests/ui`: A New Order [7/N]) - rust-lang/rust#142179 (store `target.min_global_align` as an `Align`) - rust-lang/rust#142183 (Added test for 30904) - rust-lang/rust#142194 (Remove all unused feature gates from the compiler) - rust-lang/rust#142199 (Do not free disk space in the `mingw-check-tidy` job) - rust-lang/rust#142210 (Run `mingw-check-tidy` on auto builds) r? `@ghost` `@rustbot` modify labels: rollup
2025-06-08Rollup merge of #142053 - heiher:loong32-none, r=wesleywiserJubilee-2/+8
Add new Tier-3 targets: `loongarch32-unknown-none*` MCP: https://github.com/rust-lang/compiler-team/issues/865 NOTE: LoongArch32 ELF object support is available starting with object v0.37.0.
2025-06-08Auto merge of #142008 - RalfJung:const-eval-error-here, r=oli-obkbors-2/+2
const-eval error: always say in which item the error occurred I don't see why "is this generic" should make a difference. It may be reasonable to key this on whether the error occurs in a `const fn` that was invoked by a const (making it non-obvious which constant it is) vs inside the body of the const. r? `@oli-obk`
2025-06-09Stabilize the "JSON is not Rust" diagnosticChayim Refael Friedman-0/+1
2025-06-08Auto merge of #141700 - RalfJung:atomic-intrinsics-part2, r=bjorn3bors-65/+88
Atomic intrinsics : use const generic ordering, part 2 This completes what got started in https://github.com/rust-lang/rust/pull/141507 by using a const generic for the ordering for all intrinsics. It is based on that PR; only the last commit is new. Blocked on: - https://github.com/rust-lang/rust/pull/141507 - https://github.com/rust-lang/rust/pull/141687 - https://github.com/rust-lang/stdarch/pull/1811 - https://github.com/rust-lang/rust/pull/141964 r? `@bjorn3`
2025-06-08Add the quickfix for increasing visibility of a private field to the ↵Chayim Refael Friedman-32/+125
private-field diagnostic (previously it was only on no-such-field) The difference between the diagnostics is that no-such-field is for record struct construction, while private-field is for dot syntax. I tried to unify them, but there is a bit of uniqueness in each. This is possible but maybe not worth it. Also, fix the quickfix when there is already a visibility to the field (replace it instead of appending to it).
2025-06-08Merge from rustcThe Miri Cronjob Bot-20/+2
2025-06-08Preparing for merge from rustcThe Miri Cronjob Bot-1/+1
2025-06-08Use the in-tree `compiler-builtins`Trevor Gross-3/+42
Many of `std`'s dependency have a dependency on the crates.io `compiler-builtins` when used with the feature `rustc-std-workspace-core`. Use a Cargo patch to select the in-tree version instead. `compiler-builtins` is also added as a dependency of `rustc-std-workspace-core` so these crates can remove their crates.io dependency in the future.
2025-06-08Correctly handle attr macros placed in cfg_attr in speculative expansionChayim Refael Friedman-20/+26
2025-06-08Remove the optimization of builtin attrs in `is_inside_macro_call()`Chayim Refael Friedman-8/+0
`#[cfg_attr]` is a builtin attr, but it may still contain a macro.
2025-06-07Rollup merge of #142065 - ↵Guillaume Gomez-14/+0
paolobarbolini:stabilize-const_eq_ignore_ascii_case, r=Mark-Simulacrum Stabilize `const_eq_ignore_ascii_case` Tracking issue: rust-lang/rust#131719 Closes rust-lang/rust#131719 FCP Completed: https://github.com/rust-lang/rust/issues/131719#issuecomment-2941829167