| Age | Commit message (Collapse) | Author | Lines |
|
|
|
|
|
|
|
De-arc trait items query
|
|
feat: Extend vscode 'run' command with optional mode argument for run…
|
|
ci: Fix cancel parallel jobs on windows
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Rollup of 15 pull requests
Successful merges:
- rust-lang/rust#135731 (Implement parsing of pinned borrows)
- rust-lang/rust#138780 (Add `#[loop_match]` for improved DFA codegen)
- rust-lang/rust#142453 (Windows: make `read_dir` stop iterating after the first error is encountered)
- rust-lang/rust#142633 (Error on invalid signatures for interrupt ABIs)
- rust-lang/rust#142768 (Avoid a bitcast FFI call in transmuting)
- rust-lang/rust#142825 (Port `#[track_caller]` to the new attribute system)
- rust-lang/rust#142844 (Enable short-ice for Windows)
- rust-lang/rust#142934 (Tweak `-Zmacro-stats` measurement.)
- rust-lang/rust#142955 (Couple of test suite fixes for cg_clif)
- rust-lang/rust#142977 (rustdoc: Don't mark `#[target_feature]` functions as ⚠)
- rust-lang/rust#142980 (Reduce mismatched-lifetime-syntaxes suggestions to MaybeIncorrect)
- rust-lang/rust#142982 (Corrected spelling mistake in c_str.rs)
- rust-lang/rust#142983 (Taint body on invalid call ABI)
- rust-lang/rust#142988 (Update wasm-component-ld to 0.5.14)
- rust-lang/rust#142993 (Update cargo)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
|
|
Update cargo
2 commits in 84709f085062cbf3c51fa507527c1b2334015178..409fed7dc1553d49cb9a8c0637d12d65571346ce
2025-06-22 23:58:39 +0000 to 2025-06-23 15:55:04 +0000
- Fix potential deadlock in `CacheState::lock` (rust-lang/cargo#15698)
- feat(toml): Parse support for multiple build scripts (rust-lang/cargo#15630)
|
|
r=Mark-Simulacrum
Update wasm-component-ld to 0.5.14
This brings in a few updates to the bundled `wasm-component-ld` dependency used by the `wasm32-wasip2` target. This primarily includes support for upcoming component model async/WASIp3 support which will be convenient to have native support for a few months from now.
|
|
r=GuillaumeGomez
rustdoc: Don't mark `#[target_feature]` functions as ⚠
Closes https://github.com/rust-lang/rust/issues/142952
|
|
Tweak `-Zmacro-stats` measurement.
It currently reports net size, i.e. size(output) - size(input). After some use I think this is sub-optimal, and it's better to just report size(output). Because for derive macros the input size is always 1, and for attribute macros it's almost always 1.
r? ```@petrochenkov```
|
|
Port `#[track_caller]` to the new attribute system
r? ``@oli-obk``
depends on https://github.com/rust-lang/rust/pull/142493
Closes rust-lang/rust#142783
(didn't add a test for this, this situation should simply never come up again, the code was simply wrong. lmk if I should add it, but it won't test something very useful)
|
|
r=oli-obk,traviscross
Add `#[loop_match]` for improved DFA codegen
tracking issue: https://github.com/rust-lang/rust/issues/132306
project goal: https://github.com/rust-lang/rust-project-goals/issues/258
This PR adds the `#[loop_match]` attribute, which aims to improve code generation for state machines. For some (very exciting) benchmarks, see https://github.com/rust-lang/rust-project-goals/issues/258#issuecomment-2732965199
Currently, a very restricted syntax pattern is accepted. We'd like to get feedback and merge this now before we go too far in a direction that others have concerns with.
## current state
We accept code that looks like this
```rust
#[loop_match]
loop {
state = 'blk: {
match state {
State::A => {
#[const_continue]
break 'blk State::B
}
State::B => { /* ... */ }
/* ... */
}
}
}
```
- a loop should have the same semantics with and without `#[loop_match]`: normal `continue` and `break` continue to work
- `#[const_continue]` is only allowed in loops annotated with `#[loop_match]`
- the loop body needs to have this particular shape (a single assignment to the match scrutinee, with the body a labelled block containing just a match)
## future work
- perform const evaluation on the `break` value
- support more state/scrutinee types
## maybe future work
- allow `continue 'label value` syntax, which `#[const_continue]` could then use.
- allow the match to be on an arbitrary expression (e.g. `State::Initial`)
- attempt to also optimize `break`/`continue` expressions that are not marked with `#[const_continue]`
r? ``@traviscross``
|
|
Implement parsing of pinned borrows
This PR implements part of #130494.
EDIT: It introduces `&pin mut $place` and `&pin const $place` as sugars for `std::pin::pin!($place)` and its shared reference equivalent, except that `$place` will not be moved when borrowing. The borrow check will be in charge of enforcing places cannot be moved or mutably borrowed since being pinned till dropped.
### Implementation steps:
- [x] parse the `&pin mut $place` and `&pin const $place` syntaxes
- [ ] borrowck of `&pin mut|const`
- [ ] support autoref of `&pin mut|const` when needed
|
|
Signed-off-by: Karan Janthe <karanjanthe@gmail.com>
|
|
Signed-off-by: Karan Janthe <karanjanthe@gmail.com>
|
|
update to literal-escaper 0.0.4 for better API without `unreachable` and faster string parsing
This is the replacement for just the part of https://github.com/rust-lang/rust/pull/138163 dealing with the changed API of unescape functionality, since that got moved into its own crate.
<del>This uses an unpublished version of literal-escaper (https://github.com/rust-lang/literal-escaper/pull/8).</del>
r? `@nnethercote`
|
|
|
|
This brings in a few updates to the bundled `wasm-component-ld`
dependency used by the `wasm32-wasip2` target. This primarily includes
support for upcoming component model async/WASIp3 support which will be
convenient to have native support for a few months from now.
|
|
Rollup of 9 pull requests
Successful merges:
- rust-lang/rust#142645 (Also emit suggestions for usages in the `non_upper_case_globals` lint)
- rust-lang/rust#142657 (mbe: Clean up code with non-optional `NonterminalKind`)
- rust-lang/rust#142799 (rustc_session: Add a structure for keeping both explicit and default sysroots)
- rust-lang/rust#142805 (Emit a single error when importing a path with `_`)
- rust-lang/rust#142882 (Lazy init diagnostics-only local_names in borrowck)
- rust-lang/rust#142883 (Add impl_trait_in_bindings tests from rust-lang/rust#61773)
- rust-lang/rust#142943 (Don't include current rustc version string in feature removed help)
- rust-lang/rust#142965 ([RTE-497] Ignore `c-link-to-rust-va-list-fn` test on SGX platform)
- rust-lang/rust#142972 (Add a missing mailmap entry)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
|
|
There is already panic-unwind to enable it.
|
|
rustc_std_internal_symbol is meant to call functions from crates where
there is no direct dependency on said crate. As they either have to be
added to symbols.o or rustc has to introduce an implicit dependency on
them to avoid linker errors. The latter is done for some things like the
panic runtime, but adding these symbols to symbols.o allows removing
those implicit dependencies.
|
|
Closes https://www.github.com/rust-lang/rust/issues/142952
|
|
Subtree sync for rustc_codegen_cranelift
The main highlight this time is a Cranelift update.
r? `@ghost`
`@rustbot` label +A-codegen +A-cranelift +T-compiler
|
|
rustc_session: Add a structure for keeping both explicit and default sysroots
Also avoid creating and cloning sysroot unnecessarily.
Implements the suggestion from https://github.com/rust-lang/rust/pull/142089#discussion_r2132204079.
r? ``@bjorn3``
|
|
|
|
|
|
Enable reproducible-build-2 for Windows MSVC
Works with MSVC if instructing the linker to avoid timestamps and deleting the PDB between compilations.
Addresses item in rust-lang/rust#128602
---
try-job: x86_64-mingw-*
try-job: x86_64-msvc-*
try-job: i686-msvc-*
|
|
Remove the deprecated unstable `concat_idents!` macro
In [rust-lang/rust#137653], the lang and libs-API teams did a joint FCP to deprecate
and eventually remove the long-unstable `concat_idents!` macro. The
deprecation is landing in 1.88, so do the removal here (target version
1.90).
This macro has been superseded by the more recent `${concat(...)}`
metavariable expression language feature, which avoids some of the
limitations of `concat_idents!`. The metavar expression is unstably
available under the [`macro_metavar_expr_concat`] feature.
History is mildly interesting here: `concat_idents!` goes back to 2011
when it was introduced with 513276e595f8 ("Add #concat_idents[] and
#ident_to_str[]"). The syntax looks a bit different but it still works
about the same:
let asdf_fdsa = "<.<";
assert(#concat_idents[asd,f_f,dsa] == "<.<");
assert(#ident_to_str[use_mention_distinction]
== "use_mention_distinction");
(That test existed from introduction until its removal here.)
Closes: https://github.com/rust-lang/rust/issues/29599
[rust-lang/rust#137653]: https://github.com/rust-lang/rust/pull/137653
[`macro_metavar_expr_concat`]: https://github.com/rust-lang/rust/issues/124225
|
|
Also avoid creating and cloning sysroot unnecessarily.
|
|
|
|
In [137653], the lang and libs-API teams did a joint FCP to deprecate
and eventually remove the long-unstable `concat_idents!` macro. The
deprecation is landing in 1.88, so do the removal here (target version
1.90).
This macro has been superseded by the more recent `${concat(...)}`
metavariable expression language feature, which avoids some of the
limitations of `concat_idents!`. The metavar expression is unstably
available under the [`macro_metavar_expr_concat`] feature.
History is mildly interesting here: `concat_idents!` goes back to 2011
when it was introduced with 513276e595f8 ("Add #concat_idents[] and
about the same:
let asdf_fdsa = "<.<";
assert(#concat_idents[asd,f_f,dsa] == "<.<");
assert(#ident_to_str[use_mention_distinction]
== "use_mention_distinction");
(That test existed from introduction until its removal here.)
Closes: https://www.github.com/rust-lang/rust/issues/29599
[137653]: https://www.github.com/rust-lang/rust/pull/137653
[`macro_metavar_expr_concat`]: https://www.github.com/rust-lang/rust/issues/124225
|
|
These tests were updated in the previous commit; while they are being
cleaned up, move them to a non-issue directory.
|
|
main.createCommands instead
|
|
rustdoc-json: Keep empty generic args if parenthesized
Because in the case of for example
pub fn my_fn3(f: impl FnMut()) {}
we want to keep `()` even if it is empty since that matches e.g. Rust syntax requirements.
This is an amendment to https://github.com/rust-lang/rust/pull/142502, so:
r? ``@aDotInTheVoid``
cc ``@nnethercote``
cc https://github.com/cargo-public-api/cargo-public-api/pull/798
|
|
Fix hang in --print=file-names in bootstrap
In an interactive context, the subprocess inherited a real tty stdin, which lead it it waiting for something to happen, even though nothing happened. By explicitly passing null as stdin we make sure an empty file is passed, which achieves the desired behavior.
Fixes rust-lang/rust#142926 (verified locally by cherry-picking the patch onto beta where I was building).
|
|
Fixes firefox copy paste issue
|
|
compiletest: Improve diagnostics for line annotation mismatches
When some line annotations are missing or misplaced, compiletest reports an error, but the error is not very convenient.
This PR attempts to improve the user experience.
- The "expected ... not found" messages are no longer duplicated.
- The `proc_res.status` and `proc_res.cmdline` message is no longer put in the middle of other messages describing the annotation mismatches, it's now put into the end.
- Compiletest now makes suggestions if there are fuzzy matches between expected and actually reported errors (e.g. the annotation is put on a wrong line).
- Missing diagnostic kinds are no longer produce an error eagerly, but instead treated as always mismatching kinds, so they can produce suggestions telling the right kind.
I'll post screenshots in the thread below, but the behavior shown on the screenshots can be reproduced locally using the new test `tests/ui/compiletest-self-test/line-annotation-mismatches.rs`.
This also fixes https://github.com/rust-lang/rust/issues/140940.
r? ``@jieyouxu``
|
|
Update to literal-escaper 0.0.4
|
|
Cleanup `folding_ranges` and support more things
|
|
|
|
fix: In "Wrap return type" assist, don't wrap exit points if they already have the right type
|