Yotam Ofek
bcb287dca5
librustdoc: remove unneeded #[recursion_limit]
2025-06-28 19:13:38 +00:00
Yotam Ofek
09e4ee5fbc
librustdoc: remove unneeded #[allow]s
2025-06-28 19:13:25 +00:00
bors
11ad40bb83
Auto merge of #142625 - cjgillot:inline-nocycle, r=oli-obk
...
Only compute recursive callees once.
Inlining MIR in a cyclic call graph may create query cycles, which are ICEs. The current implementation `mir_callgraph_reachable(inlining_candidate, being_optimized)` checks if calling `inlining_candidate` may cycle back to `being_optimized` that we are currently inlining into.
This PR replaces this device with query `mir_callgraph_cyclic(being_optimized)` which searches the call graph for all cycles going back to `being_optimized`, and returns the set of functions involved in those cycles.
This is a tradeoff:
- in the current implementation, we perform more walks, but shallower;
- in this new implementation, we perform fewer walks, but exhaust the graph.
I'd have liked to compute this using some kind of SCC, but generic parameters make resolution path-dependent, so usual graph algorithms do not apply.
2025-06-28 19:11:42 +00:00
Antoni Boucher
eb4d429515
Fix for libgccjit 12
2025-06-28 14:55:31 -04:00
Antoni Boucher
144989400e
Fix to use Function instead of RValue
2025-06-28 14:51:16 -04:00
Antoni Boucher
5735bb39ab
Merge branch 'master' into sync_from_rust_2025_06_02
2025-06-28 14:49:27 -04:00
Antoni Boucher
7c71c8388f
Fix type_name intrinsic
2025-06-28 14:44:54 -04:00
Kivooeo
3d81af8c55
moved tests
2025-06-28 23:12:32 +05:00
bohan
f99cdf8b1c
explain ImportData::imported_module
2025-06-29 00:23:35 +08:00
наб
45204ef4f4
"set by Rusts options". Remove misleading always-true if cfg!(unix). Drop #![feature(rustc_private)]
2025-06-28 17:57:57 +02:00
bors
7ba34c7045
Auto merge of #142317 - compiler-errors:perf-fold, r=lcnr
...
Don't fold in Instantiate when there's nothing to fold
Maybe this helps idk
r? lcnr
2025-06-28 13:31:12 +00:00
Florian Sextl
1c25bfba9d
move discr=varid check to layout_sanity_check
2025-06-28 14:47:27 +02:00
Kivooeo
f4502b8f0e
cleaned up some tests
2025-06-28 17:04:16 +05:00
Florian Sextl
3d968973c9
fix docs of FakeBorrowKind
2025-06-28 13:54:51 +02:00
Florian Sextl
ac6cfdef13
improve TagEncoding docs
2025-06-28 13:54:51 +02:00
Jonathan Brouwer
1249c14232
Port #[link_name] to the new attribute parsing infrastructure
...
Co-authored-by: Anne Stijns <anstijns@gmail.com >
Signed-off-by: Jonathan Brouwer <jonathantbrouwer@gmail.com >
2025-06-28 13:53:37 +02:00
Ralf Jung
85357d1e5c
update lockfile
2025-06-28 13:33:12 +02:00
Kivooeo
aac948b702
cleaned up some tests
2025-06-28 16:24:17 +05:00
Kornel
c9ef11695f
Keep inlined var_debug_info only when full debug info is used
2025-06-28 12:22:49 +01:00
Kornel
db9daab1ee
Test MIR inlined var debug info
2025-06-28 12:20:45 +01:00
Tshepang Mbambo
bc00a633c6
fix typos on some doc comments
2025-06-28 13:13:59 +02:00
bors
b63223c152
Auto merge of #141759 - 1c3t3a:discriminants-query, r=saethlin
...
Insert checks for enum discriminants when debug assertions are enabled
Similar to the existing null-pointer and alignment checks, this checks for valid enum discriminants on creation of enums through unsafe transmutes. Essentially this sanitizes patterns like the following:
```rust
let val: MyEnum = unsafe { std::mem::transmute<u32, MyEnum>(42) };
```
An extension of this check will be done in a follow-up that explicitly sanitizes for extern enum values that come into Rust from e.g. C/C++.
This check is similar to Miri's capabilities of checking for valid construction of enum values.
This PR is inspired by saethlin@'s PR
https://github.com/rust-lang/rust/pull/104862 . Thank you so much for keeping this code up and the detailed comments!
I also pair-programmed large parts of this together with vabr-g@.
r? `@saethlin`
2025-06-28 10:25:00 +00:00
Ralf Jung
d6f94358d8
Merge pull request #4418 from RalfJung/native-lib-tracing
...
various minor native-lib-tracing tweaks
2025-06-28 10:22:05 +00:00
Tshepang Mbambo
84abd4efbc
Merge pull request #2481 from xizheyin/submit-in-rdg-or-r
...
Explain where rdg changes should be submitted
2025-06-28 12:11:05 +02:00
Chris Denton
953cf27c7a
Workaround for mem safety in third party dlls
2025-06-28 09:59:42 +00:00
ywxt
36462f901e
Correct comments.
2025-06-28 17:58:21 +08:00
ywxt
0ff1fb27d3
Restore to HashSet
...
Co-authored-by: Zoxc <zoxc32@gmail.com >
2025-06-28 17:58:21 +08:00
ywxt
46e18d1fe0
Add FIXMEs for those ignored tests.
2025-06-28 17:58:21 +08:00
ywxt
44e69f592f
Add a comment for the wait_for_jobs function.
...
Co-authored-by: Zoxc <zoxc32@gmail.com >
2025-06-28 17:58:20 +08:00
ywxt
0ceac216c9
Only work-steal in the main loop for rustc_thread_pool
...
Co-authored-by: Zoxc <zoxc32@gmail.com >
2025-06-28 17:58:20 +08:00
Ralf Jung
5e14d0f193
move all the message types into one place
2025-06-28 11:55:46 +02:00
Lukas Wirth
7d5579d5e4
Merge pull request #20118 from Veykril/push-nolsxzxmykls
...
ci: Fix up release workflow
2025-06-28 09:54:42 +00:00
Ralf Jung
cde1012082
de-intend some code, and extend comments
2025-06-28 11:36:40 +02:00
Ralf Jung
62bb6216ea
various minor native-lib-tracing tweaks, and disable naive-lib-tracing mode by default
2025-06-28 11:36:40 +02:00
Lukas Wirth
0f93d8ae88
ci: Fix up release workflow
2025-06-28 11:35:55 +02:00
Guillaume Gomez
1052ddda96
Add regression test for #137857 to ensure that we generate intra doc links for extern crate items.
2025-06-28 11:27:12 +02:00
Yotam Ofek
00b64f8851
Use tidy to sort sym::* items
2025-06-28 09:25:55 +00:00
dswij
428208eb9b
Fix disallowed_script_idents FP on identifiers with _ ( #15123 )
...
Closes rust-lang/rust-clippy#15116
The cause for this issue is that `_` belongs to the `Common` catagory in
unicode instead of `Latin` like other ASCII alphabets. Since ASCII
characters are always allowed, I just added an extra `is_ascii()` check
to ensure this.
changelog: [`disallowed_script_idents`] fix FP on identifiers with `_`
2025-06-28 08:48:07 +00:00
dswij
8633bcbc3c
zero_ptr: lint in const context as well (#15152 )
...
The lint was extra restrictive, and didn't suggest using
`core::ptr::null` and `core::ptr::null_mut` in `const` contexts although
they have been const-stabilized since Rust 1.24.
changelog: [`zero_ptr`]: lint in `const` context as well
@rustbot label +I-false-negative +C-bug
2025-06-28 08:46:57 +00:00
Ralf Jung
96a70e2e91
Merge pull request #4417 from rust-lang/rustup-2025-06-28
...
Automatic Rustup
2025-06-28 07:40:14 +00:00
Lukas Wirth
9cd5826ba8
Merge pull request #20116 from Veykril/push-uypnmlyvotlm
...
ci: Cancel workflow only after the main matrix has finished
2025-06-28 07:39:35 +00:00
xizheyin
98c347049e
Add a link to rust-forge to explain where rdg changes should be submitted
...
Signed-off-by: xizheyin <xizheyin@smail.nju.edu.cn >
2025-06-28 15:37:54 +08:00
Lukas Wirth
ea2e04236a
ci: Cancel workflow only after the main matrix has finished
2025-06-28 09:28:26 +02:00
Ralf Jung
35e6def487
clippy
2025-06-28 09:12:51 +02:00
The Miri Cronjob Bot
cff5a7cb29
fmt
2025-06-28 05:03:27 +00:00
The Miri Cronjob Bot
3d8d4d4545
Merge from rustc
2025-06-28 05:02:19 +00:00
The Miri Cronjob Bot
34949e30d3
Preparing for merge from rustc
2025-06-28 04:55:04 +00:00
bors
d41e12f1f4
Auto merge of #143116 - matthiaskrgr:rollup-zy9ez06, r=matthiaskrgr
...
Rollup of 9 pull requests
Successful merges:
- rust-lang/rust#139858 (New const traits syntax)
- rust-lang/rust#140809 (Reduce special casing for the panic runtime)
- rust-lang/rust#142730 (suggest declaring modules when file found but module not defined)
- rust-lang/rust#142806 (Normalize before computing ConstArgHasType goal in new solver)
- rust-lang/rust#143046 (const validation: properly ignore zero-sized UnsafeCell)
- rust-lang/rust#143092 (const checks for lifetime-extended temporaries: avoid 'top-level scope' terminology)
- rust-lang/rust#143096 (tag_for_variant: properly pass TypingEnv)
- rust-lang/rust#143104 (hir_analysis: prohibit `dyn PointeeSized`)
- rust-lang/rust#143106 (gce: don't ICE on non-local const)
Failed merges:
- rust-lang/rust#143036 (Remove support for `dyn*` from the compiler)
r? `@ghost`
`@rustbot` modify labels: rollup
2025-06-27 23:15:35 +00:00
bors
06a87e91c9
Auto merge of #143116 - matthiaskrgr:rollup-zy9ez06, r=matthiaskrgr
...
Rollup of 9 pull requests
Successful merges:
- rust-lang/rust#139858 (New const traits syntax)
- rust-lang/rust#140809 (Reduce special casing for the panic runtime)
- rust-lang/rust#142730 (suggest declaring modules when file found but module not defined)
- rust-lang/rust#142806 (Normalize before computing ConstArgHasType goal in new solver)
- rust-lang/rust#143046 (const validation: properly ignore zero-sized UnsafeCell)
- rust-lang/rust#143092 (const checks for lifetime-extended temporaries: avoid 'top-level scope' terminology)
- rust-lang/rust#143096 (tag_for_variant: properly pass TypingEnv)
- rust-lang/rust#143104 (hir_analysis: prohibit `dyn PointeeSized`)
- rust-lang/rust#143106 (gce: don't ICE on non-local const)
Failed merges:
- rust-lang/rust#143036 (Remove support for `dyn*` from the compiler)
r? `@ghost`
`@rustbot` modify labels: rollup
2025-06-27 23:15:35 +00:00
Jonathan Brouwer
58418d881a
Fix rustdoc not correctly showing attributes with re-exports
...
Signed-off-by: Jonathan Brouwer <jonathantbrouwer@gmail.com >
2025-06-27 23:31:25 +02:00