Repository navigation
Rollup of 13 pull requests - #164316
Closed
JonathanBrouwer wants to merge 33 commits into
Closed
Rollup of 13 pull requests#164316JonathanBrouwer wants to merge 33 commits into
JonathanBrouwer wants to merge 33 commits into
Conversation
Older versions of ld.bfd didn't support short import libraries like the builtin implementation of rustc generates. So we worked around this by using binutils dlltool, which produces the old import library format. We have now bumped the minimum supported ld.bfd version to one which does support them, so we can drop the dlltool usage. This makes cross-compilation a bit easier and removes a bunch of code in rustc.
…enerate links to the mentioned methods
…are none if the `rustc_must_implement_one_of` attribute is present
…test improvements for same
PR 163857 changed the span representation and reduced `eq_ctxt` to a trivial equality check, which means `span_a.ctxt() == span_b.ctxt()` is now an ok alternative to `span_a.eq_ctxt(span_b)`. This commit removes `span_use_eq_ctxt` because it's no longer necessary. `eq_ctxt` remains because removing it would cause some churn; it might be worth doing as a follow-up.
This drops the `GetConsoleOutputCP` call, which would otherwise do an RPC to the console server (= slow). This leaves us with `is_console` which was using another RPC via `GetConsoleMode` (= doubly slow). On Windows 8+ we can just use `NtQueryVolumeInformationFile()` to test for `FILE_DEVICE_CONSOLE`, resulting in a ~2x console stdout speedup.
…O8Ki Stop using dlltool for generating import libraries on MinGW Older versions of ld.bfd didn't support short import libraries like the builtin implementation of rustc generates. So we worked around this by using binutils dlltool, which produces the old import library format. We have now bumped the minimum supported ld.bfd version to one which does support them, so we can drop the dlltool usage. This makes cross-compilation a bit easier and removes a bunch of code in rustc. This implements rust-lang/compiler-team#1029 with the exception of removing `-Cdlltool` support immediately rather than doing a two step migration.
…rcote Recover missing `turbofish` for `lifetime` arguments in expression position Fixes rust-lang#162656. `Struct<'a> { .. }` and `f<'_>()` were parsed as a `<` comparison whose RHS is a label, producing a cascade of unrelated errors. `parse_path_segment` now accepts `<` followed by a lifetime and `>`/`,` in expression paths, emits one "use `::<...>`" suggestion, and parses the args normally.Since the recovery is inside the path parser, `path.span` and chained forms (`::new()`, `.method()`, `?`) work without AST fix-ups or new `Parser` state; it is guarded by `may_recover()`. cc @estebank
…sole, r=ChrisDenton Prefer WriteConsoleW for stdout on Windows This PR reverts rust-lang#159562 and changes stdout on Windows such that all writes use `WriteConsoleW` _if_ stdout refers to a console. This drops the `GetConsoleOutputCP` call, which would otherwise do an RPC to the console server (= slow). This leaves us with `is_console` which was using another RPC via `GetConsoleMode` (= doubly slow). On Windows 8+ we can just use `NtQueryVolumeInformationFile()` to test for `FILE_DEVICE_CONSOLE`, resulting in a ~2x console stdout speedup. ### Linewise output of `RELEASES.md`: Output | Version | lines/s | MB/s | Speedup --------|----------|--------:|------:|-------- console | 1.99.0 | 31526 | 1.79 | console | nightly | 29251 | 1.66 | console | **this** | 67294 | 3.82 | 2.13x `NUL` | 1.99.0 | 784311 | 44.50 | `NUL` | nightly | 776529 | 44.06 | `NUL` | **this** | 1141618 | 64.78 | 1.46x The console output speedup is very noticeable here, as the time to run drops from 0.6s to just 0.25s. ### 128KiB chunked passthrough of `enwik8`: Output | Version | MB/s | Speedup --------|----------|--------:|-------- console | 1.99.0 | 86.99 | console | nightly | 165.27 | 1.90x console | **this** | 165.61 | 1.90x `NUL` | 1.99.0 | 1123.82 | `NUL` | nightly | 1137.30 | `NUL` | **this** | 1289.35 | The limiting factor here is `MAX_BUFFER_SIZE` which deserves to be refactored in another PR in my opinion.
…khyperia test DSL eagerly handle false constraints For Context: rust-lang/project-assumptions-on-binders#57 Changelog: After getting the `constraints`, I immediately check whether it’s `false`, and if so, report an error right away. The issue mentions two places: one is when `forall` as a whole returns false, and the other is when there’s a `false constraints` at the top level. So the changes to `wfcheck.rs` cover both cases. For the latter, maybe need to clear the existing `constraints`; otherwise it reports "higher-ranked lifetime bound could not be satisfied". I clear them by overwriting with `new_true`. I considered saving the old value and restoring it afterwards, but I think that’s more trouble than it’s worth. :) finally, I added relevant test files following the pattern of other test files, and they pass. llm disclosure: everything related to this issue was handwritten by me, with no LLM assistance. thank you for your time!
…-not-real-and-cannot-hurt-you, r=clarfonthey Document zero-sized allocations properly for `Box` and `Vec` Fixes rust-lang#162799
…fix, r=TaKO8Ki
Parse move exprs as a bottom expr instead of a prefix expr
`move(…)` is obviously meant to be a normal expr but since it was incorrectly treated as a prefix expr in the compiler, it meant it couldn't be used as the (left) operand of what I personally call "higher postfix operations"[^1], namely *Try*, *Call* / *Index* & "*Dot*" (*Field*, *Await*, …).
More concretely, it would mean we'd reject expressions like `move(…)?` (*Try*), `move(…)(…)` (*Call*), `move(…)[…]` (*Index*), `move(…).field` (*Field*), `move(…).method(…)` (*MethodCall*) or `move(…).await` (*Await*).
Furthermore, it would mean we'd parse `return move(0).field` like `(return move(0)).field` instead of `return ((move(0)).field)`.
---
It's immaterial whether the final version of move exprs continues to use syntax `move(…)` (a syntax much contended over at the RFC) or if it gets changed along the way (to e.g., `move { … }` (also quite controversial)), it remains a fact that move exprs are not prefix exprs!
---
CC @TaKO8Ki @nikomatsakis (rust-lang#155023)
Part of rust-lang#155050.
<sub>(No LLM was or will be used by me during the entire creation process of this PR)</sub>
[^1]: I.e., operations where the corresponding operator precedence is higher than or equal to the one of *Try*.
…1999 Fix `diagnostic::on_unknown` format placeholder for paths in expressions and type paths See rust-lang#163636 (comment) for context
…up, r=ChrisDenton Windows FileExt trait doesn't need to handle ErrorKind::Interrupted; test improvements for same This PR: * Fixes the Windows `FileExt` `seek_read_exact()`, `seek_read_buf_exact()`, and `seek_write_all()` methods to pass up *all* errors as `ErrorKind::Interrupted` does not occur natively on Windows * Adds a new test to make sure `ErrorKind::Interrupted` is handled correctly * Cleans up existing tests and adds call counting checks No LLMs were used in writing this PR. Um, no Windows were locally used in writing this PR, either. I did my best with GitHub's CI to make sure these test work, but... can BORS be made to do a Windows only test on this PR first? I don't want to be the one messing up the merge again, haha.
…t_one_of, r=Urgau rustdoc: Improvements for `rustc_must_implement_one_of` Fixes rust-lang#163675. Funnily enough, most things are actually already there, so this PR is only an improvement over the following: * The methods listed in the note are now links. * The note itself got a little display improvement (unified with the existing ones mostly, screenshots below). * Added the `Required Methods` heading in the sidebar if `rustc_must_implement_one_of` is used Before: <img width="407" height="114" alt="Screenshot From 2026-10-13 16-30-39" src="https://github.com/user-attachments/assets/ccbe09bd-437a-45ab-a6ae-e77f02c68b19" /> After: <img width="454" height="121" alt="Screenshot From 2026-10-13 16-30-47" src="https://github.com/user-attachments/assets/62b4e7a7-b727-4e25-ade4-7e530fd110cb" /> r? @Urgau
Add regression test for rust-lang#155977 The ICE was fixed by rust-lang#156976. I checked the final test on its base build, `3c00c96d` (ICE), and its unrolled build, `5d29849f` (E0277, no ICE). The test checks that this higher-ranked where-clause example fails to compile instead of causing an ICE in the new trait solver. Closes rust-lang#155977 cc @lcnr
Member
Author
Contributor
This comment has been minimized.
This comment has been minimized.
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 14, 2026
Rollup of 13 pull requests try-job: dist-various-1 try-job: test-various try-job: test-x86_64-gnu-aux try-job: test-x86_64-msvc-1 try-job: test-aarch64-apple-1 try-job: test-aarch64-apple-2 try-job: test-x86_64-mingw-1 try-job: test-i686-msvc try-job: test-armhf-gnu try-job: test-x86_64-gnu-llvm-22-3
Collaborator
|
The job Click to see the possible cause of the failure (guessed by this bot) |
Member
Author
|
@bors try jobs=test-x86_64-mingw-1 |
This comment has been minimized.
This comment has been minimized.
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 14, 2026
Rollup of 13 pull requests try-job: test-x86_64-mingw-1
Contributor
|
PR #157712, which is a member of this rollup, was unapproved. This rollup was thus unapproved. |
Contributor
|
💔 Test for cabc0b4 failed: CI. Failed job:
|
Collaborator
|
The job Click to see the possible cause of the failure (guessed by this bot) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Successful merges:
turbofishforlifetimearguments in expression position #162749 (Recover missingturbofishforlifetimearguments in expression position)BoxandVec#163230 (Document zero-sized allocations properly forBoxandVec)diagnostic::on_unknownformat placeholder for paths in expressions and type paths #164178 (Fixdiagnostic::on_unknownformat placeholder for paths in expressions and type paths)rustc_must_implement_one_of#164266 (rustdoc: Improvements forrustc_must_implement_one_of)span_use_eq_ctxtlint #164292 (Remove thespan_use_eq_ctxtlint)r? @ghost
Create a similar rollup