about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorLines
2025-08-25Wait for DPkg frontend lock when trying to remove packagesJieyou Xu-3/+6
2025-08-25Override `GITHUB_ACTIONS=0` for tidy testsJakub Beránek-1/+4
2025-08-25Merge pull request #4543 from RalfJung/tb-sifaRalf Jung-12/+12
TB: fix SIFA comment
2025-08-25TB: fix SIFA commentRalf Jung-12/+12
2025-08-25Do not forward CI configure arguments to `distcheck` buildsJakub Beránek-1/+8
2025-08-25Handle tarballs in `x test tidy`Jakub Beránek-0/+6
2025-08-25Make `x test distcheck` more self-containedJakub Beránek-24/+36
2025-08-25Rollup merge of #145842 - tshepang:rdg-sync, r=jieyouxuStuart Cook-104/+167
rustc-dev-guide subtree update Subtree update of `rustc-dev-guide` to https://github.com/rust-lang/rustc-dev-guide/commit/a03c1efa970bb695db9dfda35e8793e2160863ff. Created using https://github.com/rust-lang/josh-sync. r? `@ghost`
2025-08-25Rollup merge of #145794 - he32:bootstrap-netbsd-fix, r=KobzolStuart Cook-1/+13
bootstrap.py: Improve CPU detection on NetBSD ...and add some adaptation of detection for some arm variants.
2025-08-25Fix ExprStmt delete semicolon for toggle_macro_delimiterA4-Tacks-3/+33
2025-08-25add span to struct pattern rest (..)Valdemar Erk-7/+8
2025-08-25Merge ref 'a1dbb443527b' from rust-lang/rustThe Miri Cronjob Bot-184/+662
Pull recent changes from https://github.com/rust-lang/rust via Josh. Upstream ref: a1dbb443527bd126452875eb5d5860c1d001d761 Filtered ref: e644bd7324c7e071785356fcaad5bd89e671366b This merge was created using https://github.com/rust-lang/josh-sync.
2025-08-25Prepare for merging from rust-lang/rustThe Miri Cronjob Bot-1/+1
This updates the rust-version file to a1dbb443527bd126452875eb5d5860c1d001d761.
2025-08-25Merge ref 'a1dbb443527b' from rust-lang/rustThe rustc-josh-sync Cronjob Bot-7145/+13342
Pull recent changes from https://github.com/rust-lang/rust via Josh. Upstream ref: a1dbb443527bd126452875eb5d5860c1d001d761 Filtered ref: c2339048a82c55166f9b9ee83fd618be252a6e23 This merge was created using https://github.com/rust-lang/josh-sync.
2025-08-25Prepare for merging from rust-lang/rustThe rustc-josh-sync Cronjob Bot-1/+1
This updates the rust-version file to a1dbb443527bd126452875eb5d5860c1d001d761.
2025-08-24Auto merge of #137229 - GuillaumeGomez:expand-macro, r=lolbinarycatbors-92/+561
Add support for macro expansion in rustdoc source code pages This is what it looks like: ![Screenshot From 2025-02-18 18-08-51](https://github.com/user-attachments/assets/ce2b3806-6218-47df-94bf-e9e9ed40cd41) ![image](https://github.com/user-attachments/assets/891042db-8632-4dba-9343-e28570c058fe) You can test it [here](https://rustdoc.crud.net/imperio/macro-expansion/src/lib/lib.rs.html). In this case, I also enabled the `--generate-link-to-definition` to show that both options work well together. Note: <del>There is a bug currently in firefox where the line numbers are not displayed correctly if they're inside the "macro expansion" span: https://bugzilla.mozilla.org/show_bug.cgi?id=1949948<del> Found a workaround around this bug. r? `@notriddle`
2025-08-24compiletest: if a compiler fails outside a ui test, show its outputbinarycat-2/+3
2025-08-24Auto merge of #145812 - karolzwolak:attrs-in-fields-and-variants-section, ↵bors-4/+22
r=GuillaumeGomez rustdoc: render attributes in Field and Variants sections Follow up to rust-lang/rust#145782. Render attributes in Field and Variants sections. Associated constants and methods are already rendered with attributes in their sections, so I figured out fields and variants should too. (no change here) <img width="378" height="265" alt="image" src="https://github.com/user-attachments/assets/b4f45c42-0146-486e-8881-138d2a7ad1c4" /> r? `@GuillaumeGomez` --- Before (left) / after (right): <img width="396" height="519" alt="image" src="https://github.com/user-attachments/assets/18288e13-09e7-448c-ba98-2023fa6df597" /> <img width="382" height="597" alt="image" src="https://github.com/user-attachments/assets/e624dc84-d169-41cc-bb89-7a1c2b2bb3e3" /> <img width="371" height="313" alt="image" src="https://github.com/user-attachments/assets/29833645-0b93-4900-80a8-c5a1e0b541b4" /> <img width="371" height="331" alt="image" src="https://github.com/user-attachments/assets/d5ce4b9e-f7f1-4f36-8ac0-08b0b5077e48" /> <img width="362" height="309" alt="image" src="https://github.com/user-attachments/assets/0436a51d-29a5-4403-a27c-7697524f807a" /> <img width="357" height="332" alt="image" src="https://github.com/user-attachments/assets/9a759fc5-30e7-4bbb-a88a-a3e3d1ed02aa" />
2025-08-24Fix rust-analyzer-contributors referenceEmmanuel Ferdman-1/+1
Signed-off-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>
2025-08-24fix: Masquerade as nightly cargo when invoking flycheck with `-Zscript`Shoyu Vanilla-0/+1
2025-08-24Merge pull request #2550 from WaffleLapkin/try-borswaffle-37/+28
Suggest using `@bors try jobs=...`
2025-08-24Auto merge of #145384 - ywxt:parallel-tests, r=jieyouxubors-1/+17
Add more tests for the parallel rustc At the moment, the parallel frontend test cases are severely lacking. Althought some reported issues have been resolved, they haven't been added into the tests. This PR arranges the resolved ICE issues and adds tests for them. Whether it is worthwhile to add a separate test suite for the paralel frontend still requires futher discussion. But we are trying coveraging issues being resolved through capability of the existing UI test suite. Discussion: [Zulip](https://rust-lang.zulipchat.com/#narrow/channel/233931-t-compiler.2Fmajor-changes/topic/Proposal.20for.20a.20dedicated.20test.20suite.20for.20t.E2.80.A6.20compiler-team.23906) Related issues: - rust-lang/rust#120760 - rust-lang/rust#124423 fixed by rust-lang/rust#140358 - rust-lang/rust#127971 fxied by rust-lang/rust#140358 - rust-lang/rust#120601 fixed by rust-lang/rust#127311 cc `@jieyouxu`
2025-08-24rustdoc: render attributes in Field and Variants sectionsKarol Zwolak-4/+22
2025-08-24bootstrap.py: follow up more 'tidy' insistence (string quotes).Havard Eidnes-2/+2
2025-08-24Fix some minor issues in commentshoupo-bob-6/+6
Signed-off-by: houpo-bob <houpocun@outlook.com>
2025-08-24Merge pull request #20523 from ChayimFriedman2/opaque-genericsShoyu Vanilla (Flint)-43/+54
fix: Fix opaque generics
2025-08-24Fix opaque genericsChayim Refael Friedman-43/+54
The parent generics were incorrectly not considered for TAIT. I'm not convinced we should follow rustc here, also there are items (opaques) with more than 1 parent (opaque -> fn/type alias -> impl/trait) and I'm not sure we properly account for that in all places, but for now I left it as-is. Also fix a bug where lifetimes' indices were incorrect when there is a self param (they started from 0 instead of 1).
2025-08-24fmtThe Miri Cronjob Bot-1/+2
2025-08-24Merge ref 'f6d23413c399' from rust-lang/rustThe Miri Cronjob Bot-1925/+2812
Pull recent changes from https://github.com/rust-lang/rust via Josh. Upstream ref: f6d23413c399fb530be362ebcf25a4e788e16137 Filtered ref: fc132ae45e682a2556f99caed7bca9b8a2e909c8 This merge was created using https://github.com/rust-lang/josh-sync.
2025-08-24Prepare for merging from rust-lang/rustThe Miri Cronjob Bot-1/+1
This updates the rust-version file to f6d23413c399fb530be362ebcf25a4e788e16137.
2025-08-23Rollup merge of #145798 - compiler-errors:unnamed-lt-primary, r=lqdJacob Pratt-2/+2
Use unnamed lifetime spans as primary spans for `MISMATCHED_LIFETIME_SYNTAXES` Fixes https://github.com/rust-lang/rust/issues/145772 This PR changes the primary span(s) of the `MISMATCHED_LIFETIME_SYNTAXES` to point to the *unnamed* lifetime spans in both the inputs and *outputs* of the function signature. As reported in rust-lang/rust#145772, this should make it so that IDEs highlight the spans of the actionable part of this lint, rather than just the (possibly named) input spans like they do today. This could be tweaked further perhaps, for example for `fn foo(_: T<'_>) -> T`, we don't need to highlight the elided lifetime if the actionable part is to change only the return type to `T<'_>`, but I think it's improvement on what's here today, so I think that should be follow-up since I think the logic might get a bit hairy. cc ```@shepmaster```
2025-08-23Rollup merge of #145554 - tshepang:rdg-sync, r=BoxyUwUJacob Pratt-18/+16
rustc-dev-guide subtree update Subtree update of `rustc-dev-guide` to https://github.com/rust-lang/rustc-dev-guide/commit/c22150808bc96df8c8666d2f4b89cbab10e1ce0d. Created using https://github.com/rust-lang/josh-sync. r? ```@ghost```
2025-08-23Rollup merge of #144531 - Urgau:int_to_ptr_transmutes, r=jackh726Jacob Pratt-67/+44
Add lint against integer to pointer transmutes # `integer_to_ptr_transmutes` *warn-by-default* The `integer_to_ptr_transmutes` lint detects integer to pointer transmutes where the resulting pointers are undefined behavior to dereference. ### Example ```rust fn foo(a: usize) -> *const u8 { unsafe { std::mem::transmute::<usize, *const u8>(a) } } ``` ``` warning: transmuting an integer to a pointer creates a pointer without provenance --> a.rs:1:9 | 158 | std::mem::transmute::<usize, *const u8>(a) | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = note: this is dangerous because dereferencing the resulting pointer is undefined behavior = note: exposed provenance semantics can be used to create a pointer based on some previously exposed provenance = help: if you truly mean to create a pointer without provenance, use `std::ptr::without_provenance_mut` = help: for more information about transmute, see <https://doc.rust-lang.org/std/mem/fn.transmute.html#transmutation-between-pointers-and-integers> = help: for more information about exposed provenance, see <https://doc.rust-lang.org/std/ptr/index.html#exposed-provenance> = note: `#[warn(integer_to_ptr_transmutes)]` on by default help: use `std::ptr::with_exposed_provenance` instead to use a previously exposed provenance | 158 - std::mem::transmute::<usize, *const u8>(a) 158 + std::ptr::with_exposed_provenance::<u8>(a) | ``` ### Explanation Any attempt to use the resulting pointers are undefined behavior as the resulting pointers won't have any provenance. Alternatively, `std::ptr::with_exposed_provenance` should be used, as they do not carry the provenance requirement or if the wanting to create pointers without provenance `std::ptr::without_provenance_mut` should be used. See [std::mem::transmute] in the reference for more details. [std::mem::transmute]: https://doc.rust-lang.org/std/mem/fn.transmute.html -------- People are getting tripped up on this, see https://github.com/rust-lang/rust/issues/128409 and https://github.com/rust-lang/rust/issues/141220. There are >90 cases like these on [GitHub search](https://github.com/search?q=lang%3Arust+%2Ftransmute%3A%3A%3Cu%5B0-9%5D*.*%2C+%5C*const%2F&type=code). Fixes https://github.com/rust-lang/rust-clippy/issues/13140 Fixes https://github.com/rust-lang/rust/issues/141220 Fixes https://github.com/rust-lang/rust/issues/145523 `@rustbot` labels +I-lang-nominated +T-lang cc `@traviscross` r? compiler
2025-08-24Merge pull request #2548 from joshtriplett/macro-parser许杰友 Jieyou Xu (Joe)-35/+21
2025-08-24Merge pull request #20507 from A4-Tacks/suggest-return-exprChayim Refael Friedman-3/+54
Add ReturnExpr completion suggest
2025-08-24Add ReturnExpr completion suggestA4-Tacks-3/+54
2025-08-24Merge pull request #20512 from A4-Tacks/arith-op-not-on-selectedChayim Refael Friedman-1/+16
replace_arith_op not applicable on selected
2025-08-24replace_arith_op not applicable on selectedA4-Tacks-1/+16
2025-08-24Add an option to remove reborrows from adjustment inlay hintsChayim Refael Friedman-5/+88
Reborrows are consecutive deref then ref. Make it the default because reborrows are mostly useless to the programmer. Also rename `rust-analyzer.inlayHints.expressionAdjustmentHints.enable: "reborrow"` to `rust-analyzer.inlayHints.expressionAdjustmentHints.enable: "borrows"`, as it's not about reborrows but about any ref/deref and it's confusing with the new setting.
2025-08-23Merge pull request #20513 from A4-Tacks/let-in-let-chainChayim Refael Friedman-3/+17
Add let in let-chain completion support
2025-08-23Use unnamed lifetime spans as primary spans for MISMATCHED_LIFETIME_SYNTAXESMichael Goulet-2/+2
2025-08-23Merge pull request #20518 from A4-Tacks/fix-else-in-in-letChayim Refael Friedman-3/+355
Fix `else` completion in `let _ = if x {} $0`
2025-08-24Adjust clippy lints for rustc `integer_to_ptr_transmutes` lintUrgau-67/+32
2025-08-24Allow `integer_to_ptr_transmutes` in testsUrgau-0/+12
2025-08-23Merge pull request #20511 from A4-Tacks/fix-conv-int-lit-on-selectedChayim Refael Friedman-2/+8
convert_integer_literal not on selected
2025-08-23bootstrap.py: follow up tidy output from CI.Havard Eidnes-2/+3
I thought tidy would be more allergic to 80-coloumn overflow, but so be it.
2025-08-23Merge pull request #4540 from RalfJung/tb-refactorsRalf Jung-144/+116
tree borrows: refactor new-permission logic
2025-08-23refactor tb_rebor: reduce code duplicationRalf Jung-38/+22
2025-08-23tree borrows: refactor new-permission logicRalf Jung-110/+98
2025-08-23Rollup merge of #145787 - samueltardieu:push-vovspkkxsxtn, r=KobzolSamuel Tardieu-3/+3
citool: cleanup `mismatched_lifetime_syntaxes` warnings Those lifetimes are implicit earlier in the same signature, and should not be hidden in the output type.