Commit Graph

291081 Commits

Author SHA1 Message Date
Boxy
52f2c45dee Properly test whether repeat expr checks are pre/post integer fallback 2025-05-21 20:38:49 +01:00
Boxy
f60bab475e Don't allow repeat expr count inference side effects to propagate 2025-05-21 20:38:49 +01:00
Boxy
b1774b8d73 Fix tests 2025-05-21 20:20:19 +01:00
Boxy
b4079c62bd Don't evaluate constants depending on infers or params 2025-05-21 20:20:19 +01:00
Boxy
996a185ba7 Introduce tcx.anon_const_kind query 2025-05-21 20:20:19 +01:00
Ralf Jung
4a18888cad document that the entire test suite passes under freebsd 2025-05-21 21:11:03 +02:00
Boxy
6d6259f310 Document why we allow escaping bound vars in LTA norm 2025-05-21 20:09:41 +01:00
Jason Newcomb
106ac79ecb Add expect_action helper to clippy_dev 2025-05-21 15:09:35 -04:00
Jason Newcomb
544c300fb6 Improve speed of cargo dev fmt. 2025-05-21 15:09:35 -04:00
Ralf Jung
5955969543 run the full test suite under FreeBSD 2025-05-21 21:09:03 +02:00
Lukas Wirth
2580d833a2 Merge pull request #19839 from ChayimFriedman2/inlay-hints-attr
fix: Correctly set the span of the proc_macro crate's Group delimiters
2025-05-21 18:43:35 +00:00
Chayim Refael Friedman
0cb50cd99e Merge pull request #19840 from rust-lang/davidbarsky/fix-integrated-benchmarks
internal: fix `integrated_benchmarks` to make actual edits
2025-05-21 18:38:15 +00:00
Ralf Jung
e065e27e0c Merge pull request #4287 from LorrensP-2158466/freebsd-num-cpus
implement cpuset_getaffinity for freebsd
2025-05-21 18:37:51 +00:00
LorrensP-2158466
5dfcb12a20 Implement FreeBSD syscall cpuset_getaffinity. 2025-05-21 20:10:40 +02:00
David Barsky
8acb1b5f0b internal: fix integrated_benchmarks to make actual edits 2025-05-21 13:35:18 -04:00
blyxyas
f1ad1cd799 Support different lintcheck CARGO_TARGET_DIR 2025-05-21 17:24:20 +00:00
MarcoIeni
f57a64ae5a ci: improve citool job db errors 2025-05-21 18:50:01 +02:00
bors
462cc099c9 Auto merge of #141345 - matthiaskrgr:rollup-vux7gok, r=matthiaskrgr
Rollup of 7 pull requests

Successful merges:

 - #141267 (only resolve top-level guard patterns' guards once)
 - #141280 (Use Docker cache from the current repository)
 - #141296 (Async drop fix for 'broken mir, place has deref as later projection')
 - #141328 (When AsyncDrop impl is empty, sync drop generated in elaborator)
 - #141332 (Do not eagerly fold consts in `normalize_param_env_or_error` if new solver)
 - #141333 (Use `DeepRejectCtxt` in `assemble_inherent_candidates_from_param`)
 - #141334 (eagerly check nested obligations when coercing fndefs)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-05-21 16:42:18 +00:00
dianne
f2d94c1d93 unpretty=thir-tree: don't require the final expr to be the entrypoint 2025-05-21 09:32:59 -07:00
dianne
2a403dc81d lower bodies' params to thir before the body's value 2025-05-21 09:17:11 -07:00
Chayim Refael Friedman
226db317b1 Correctly set the span of the proc_macro crate's Group delimiters
Previously only the open delimiter's span was set, and this caused... weird problems.
2025-05-21 18:31:14 +03:00
Ralf Jung
febe98807f Merge pull request #4338 from RalfJung/FileDescription
FileDescription: improve read/write docs
2025-05-21 14:57:41 +00:00
bjorn3
96ac571445 Move -Zcrate-attr injection to just after crate root parsing
This way after_crate_root_parsing and -Zpretty will see them.
2025-05-21 14:32:40 +00:00
xizheyin
46a5c91591 std: fix doctest and explain for as_slices and as_mut_slices in VecDeque
Signed-off-by: xizheyin <xizheyin@smail.nju.edu.cn>
2025-05-21 22:13:23 +08:00
beetrees
3ab6af049b Use Cranelift bitcast instead of store & load to bitcast between vectors and non-vectors (#1580) 2025-05-21 15:59:52 +02:00
lcnr
5d9141c6c8 fix better_any breakage by making the solver more unsound 2025-05-21 13:54:19 +00:00
Matthias Krüger
9fd0ab6876 Rollup merge of #141334 - lcnr:coerce-nested-obligations, r=compiler-errors
eagerly check nested obligations when coercing fndefs

fixes https://github.com/rust-lang/trait-system-refactor-initiative/issues/212

r? `@compiler-errors`
2025-05-21 15:38:12 +02:00
Matthias Krüger
ab9109ad19 Rollup merge of #141333 - compiler-errors:param-env-candidate-unnorm, r=lcnr
Use `DeepRejectCtxt` in `assemble_inherent_candidates_from_param`

Fixes https://github.com/rust-lang/trait-system-refactor-initiative/issues/214

We were not properly considering unnormalized param-env candidates in `assemble_inherent_candidates_from_param`.

r? lcnr
2025-05-21 15:38:12 +02:00
Matthias Krüger
6606fd9a14 Rollup merge of #141332 - compiler-errors:no-fold-const, r=lcnr
Do not eagerly fold consts in `normalize_param_env_or_error` if new solver

Fixes https://github.com/rust-lang/trait-system-refactor-initiative/issues/213

Given:

```
trait Trait: Deref<Target = [u8; { 1 + 1 }]> {}
```

when elaborating param env for `Trait`, we have `Self: Trait`, `Self: Deref<Target = [u8; {anon const}]>`.

Before this PR, we would fold the anon consts away *before* elaborating. However, we end up getting another *un-folded* copy of the anon const from elaborating `Self: Trait`. This leads to normalization ambiguity.

r? lcnr
2025-05-21 15:38:11 +02:00
Matthias Krüger
1461ca3f39 Rollup merge of #141328 - azhogin:azhogin/async-drop-ice-for-empty-impl-fix, r=oli-obk
When AsyncDrop impl is empty, sync drop generated in elaborator

Fixes #140974.
2025-05-21 15:38:10 +02:00
Matthias Krüger
ad6fb066dd Rollup merge of #141296 - azhogin:azhogin/async-drop-broken-mir-place-deref-fix, r=oli-obk
Async drop fix for 'broken mir, place has deref as later projection'

fixes #140975

Problem in codegen fixed with an additional temporary local.
2025-05-21 15:38:10 +02:00
Matthias Krüger
7a53ef7af3 Rollup merge of #141280 - Kobzol:docker-rust-lang-cache, r=marcoieni
Use Docker cache from the current repository

This is needed to make the cache work after moving CI from the `rust-lang-ci` org to `rust-lang`. Shouldn't be merged until we actually move bors.

Context: https://github.com/rust-lang/infra-team/issues/188

r? `@marcoieni`
2025-05-21 15:38:09 +02:00
Matthias Krüger
af081a4247 Rollup merge of #141267 - dianne:fix-141265, r=oli-obk
only resolve top-level guard patterns' guards once

We resolve guard patterns' guards in `resolve_pattern_inner`, so to avoid resolving them multiple times, we must avoid doing so earlier. To accomplish this, `LateResolutionVisitor::visit_pat` contains a case for guard patterns that avoids visiting their guards while walking patterns.

This PR fixes #141265, which was due to `visit::walk_pat` being used instead; this meant guards at the top level of a pattern would be visited twice. e.g. it would ICE on `for x if x in [] {}`, but not `for (x if x) in [] {}`. `visit_pat` was already used for the guard pattern in the second example, on account of the top-level pattern being parens.
2025-05-21 15:38:08 +02:00
Folkert de Vries
d8a22a281c limit impls of VaArgSafe to just types that are actually safe
8 and 16-bit integers are subject to upcasting in C, and hence are not reliably safe. users should perform their own casting and deal with the consequences
2025-05-21 15:36:29 +02:00
bors
356f2d0774 Auto merge of #140386 - oli-obk:match-on-lang-item-kind, r=compiler-errors
Match on lang item kind instead of using an if/else chain

Similar to how the new solver does this. Just noticed while I was adding a new entry to the chain 😆
2025-05-21 13:31:13 +00:00
Philipp Krones
0e203f3914 Update Cargo.lock 2025-05-21 15:20:26 +02:00
Philipp Krones
7debaf6b44 Merge commit 'cadf98bb7d783e2ea3572446c3f80d3592ec5f86' into clippy-subtree-update 2025-05-21 15:15:38 +02:00
Philipp Krones
a0c1ed3b93 Merge commit 'cadf98bb7d783e2ea3572446c3f80d3592ec5f86' into clippy-subtree-update 2025-05-21 15:15:38 +02:00
Ben Kimock
e36dc78edd Add some track_caller info to precondition panics 2025-05-21 09:10:06 -04:00
Philipp Krones
cadf98bb7d Rustup (#14860)
r? @ghost

Quick out-of cycle sync to fix an ICE that was already reported twice

changelog: none
2025-05-21 12:55:45 +00:00
Philipp Krones
8a28b797b8 Bump nightly version -> 2025-05-21 2025-05-21 14:50:25 +02:00
Philipp Krones
910e640f9b Merge remote-tracking branch 'upstream/master' into rustup 2025-05-21 14:50:06 +02:00
Ralf Jung
4502ae8c69 bump stdarch 2025-05-21 13:41:58 +02:00
Andrew Zhogin
7c38b6fd28 Async drop fix for 'broken mir in AsyncDropGlue, place has deref as a later projection' (#140975) 2025-05-21 18:29:13 +07:00
Andrew Zhogin
dc794f18a4 When AsyncDrop impl is empty, sync drop generated in elaborator (Fixes #140974) 2025-05-21 18:18:27 +07:00
Jakub Beránek
78d3ea14f7 Add bors environment to CI
This will be used to access secrets once we move off rust-lang-ci.
2025-05-21 13:10:13 +02:00
lcnr
196c3b3ef4 eagerly check nested obligations when coercing fndefs 2025-05-21 11:09:48 +00:00
bors
c43786c9b7 Auto merge of #141331 - matthiaskrgr:rollup-k0loxj6, r=matthiaskrgr
Rollup of 7 pull requests

Successful merges:

 - #137759 (Add `std::os::unix::process::CommandExt::chroot` to safely chroot a child process)
 - #140994 (replace `cc_detect::cc2ar` with `cc::try_get_archiver`)
 - #141213 (Suggest use "{}", self.x instead of {self.x} when resolve x as field of `self`)
 - #141283 (Allow `x perf` to find rustc.exe on Windows)
 - #141284 (Allow trailing comma after argument in query definition)
 - #141317 (typeck: catch `continue`s pointing to blocks)
 - #141318 (Avoid creating an empty identifer in `Symbol::to_ident_string`.)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-05-21 10:19:04 +00:00
Michael Goulet
ad59f0b6e6 Use DeepRejectCtxt in assemble_inherent_candidates_from_param 2025-05-21 10:02:54 +00:00
Matthias Krüger
5b150e3122 Rollup merge of #141318 - nnethercote:fix-140884, r=compiler-errors
Avoid creating an empty identifer in `Symbol::to_ident_string`.

Because that causes an assertion failure in debug builds.

Fixes #140884.

r? `@oli-obk`
2025-05-21 11:28:47 +02:00