Commit Graph

268329 Commits

Author SHA1 Message Date
lcnr
1a9d2d82a5 stabilize -Znext-solver=coherence 2024-10-15 13:11:00 +02:00
bors
88f311479d Auto merge of #131724 - matthiaskrgr:rollup-ntgkkk8, r=matthiaskrgr
Rollup of 7 pull requests

Successful merges:

 - #130608 (Implemented `FromStr` for `CString` and `TryFrom<CString>` for `String`)
 - #130635 (Add `&pin (mut|const) T` type position sugar)
 - #130747 (improve error messages for `C-cmse-nonsecure-entry` functions)
 - #131137 (Add 1.82 release notes)
 - #131328 (Remove unnecessary sorts in `rustc_hir_analysis`)
 - #131496 (Stabilise `const_make_ascii`.)
 - #131706 (Fix two const-hacks)

r? `@ghost`
`@rustbot` modify labels: rollup
2024-10-15 05:02:38 +00:00
Matthias Krüger
83252bd780
Rollup merge of #131706 - GKFX:fix-const-hacks, r=tgross35
Fix two const-hacks

Fix two pieces of code marked `FIXME(const-hack)` related to const_option #67441.
2024-10-15 05:12:37 +02:00
Matthias Krüger
9716a42389
Rollup merge of #131496 - bjoernager:const-make-ascii, r=dtolnay
Stabilise `const_make_ascii`.

Closes: #130698

This PR stabilises the `const_make_ascii` feature gate (i.e. marking the `make_ascii_uppercase` and `make_ascii_lowercase` methods in `char`, `u8`, `[u8]`, and `str` as const).
2024-10-15 05:12:36 +02:00
Matthias Krüger
b9cb20154d
Rollup merge of #131328 - ismailarilik:remove-unnecessary-sorts-in-rustc-hir-analysis, r=compiler-errors
Remove unnecessary sorts in `rustc_hir_analysis`

A follow-up after #131140. Here the related objects are `IndexSet` so do not require a sort to stay stable. And they don't need to be `mut` anymore.

r? ```@compiler-errors```
2024-10-15 05:12:36 +02:00
Matthias Krüger
13e07b9edd
Rollup merge of #131137 - Mark-Simulacrum:relnotes, r=cuviper
Add 1.82 release notes

cc ````@rust-lang/release````

This is using the new release notes infrastructure. My expectation is that most and/or all edits should be made separately from this PR by updating various relnote tracking issues, and then we'll re-run the relnotes tool. That probably comes with an exception for the stabilized APIs for std, which will need to be manually added at the end.
2024-10-15 05:12:35 +02:00
Matthias Krüger
731e360d15
Rollup merge of #130747 - folkertdev:c-cmse-nonsecure-entry-error-messages, r=compiler-errors
improve error messages for `C-cmse-nonsecure-entry` functions

fixes https://github.com/rust-lang/rust/issues/81347

tracking issue: https://github.com/rust-lang/rust/issues/75835

brings error messages and testing for `C-cmse-nonsecure-entry` in line with `C-cmse-nonsecure-call`.

r? `@compiler-errors`
2024-10-15 05:12:35 +02:00
Matthias Krüger
fb691b470a
Rollup merge of #130635 - eholk:pin-reborrow-sugar, r=compiler-errors
Add `&pin (mut|const) T` type position sugar

This adds parser support for `&pin mut T` and `&pin const T` references. These are desugared to `Pin<&mut T>` and `Pin<&T>` in the AST lowering phases.

This PR currently includes #130526 since that one is in the commit queue. Only the most recent commits (bd450027eb4a94b814a7dd9c0fa29102e6361149 and following) are new.

Tracking:

- #130494

r? `@compiler-errors`
2024-10-15 05:12:34 +02:00
Matthias Krüger
3a00d35c5d
Rollup merge of #130608 - YohDeadfall:cstr-from-into-str, r=workingjubilee
Implemented `FromStr` for `CString` and `TryFrom<CString>` for `String`

The motivation of this change is making it possible to use `CString` in generic methods with `FromStr` and `TryInto<String>` trait bounds. The same traits are already implemented for `OsString` which is an FFI type too.
2024-10-15 05:12:34 +02:00
bors
785c83015c Auto merge of #129458 - EnzymeAD:enzyme-frontend, r=jieyouxu
Autodiff Upstreaming - enzyme frontend

This is an upstream PR for the `autodiff` rustc_builtin_macro that is part of the autodiff feature.

For the full implementation, see: https://github.com/rust-lang/rust/pull/129175

**Content:**
It contains a new `#[autodiff(<args>)]` rustc_builtin_macro, as well as a `#[rustc_autodiff]` builtin attribute.
The autodiff macro is applied on function `f` and will expand to a second function `df` (name given by user).
It will add a dummy body to `df` to make sure it type-checks. The body will later be replaced by enzyme on llvm-ir level,
we therefore don't really care about the content. Most of the changes (700 from 1.2k) are in `compiler/rustc_builtin_macros/src/autodiff.rs`, which expand the macro. Nothing except expansion is implemented for now.
I have a fallback implementation for relevant functions in case that rustc should be build without autodiff support. The default for now will be off, although we want to flip it later (once everything landed) to on for nightly. For the sake of CI, I have flipped the defaults, I'll revert this before merging.

**Dummy function Body:**
The first line is an `inline_asm` nop to make inlining less likely (I have additional checks to prevent this in the middle end of rustc. If `f` gets inlined too early, we can't pass it to enzyme and thus can't differentiate it.
If `df` gets inlined too early, the call site will just compute this dummy code instead of the derivatives, a correctness issue. The following black_box lines make sure that none of the input arguments is getting optimized away before we replace the body.

**Motivation:**
The user facing autodiff macro can verify the user input. Then I write it as args to the rustc_attribute, so from here on I can know that these values should be sensible. A rustc_attribute also turned out to be quite nice to attach this information to the corresponding function and carry it till the backend.
This is also just an experiment, I expect to adjust the user facing autodiff macro based on user feedback, to improve usability.

As a simple example of what this will do, we can see this expansion:
From:
```
#[autodiff(df, Reverse, Duplicated, Const, Active)]
pub fn f1(x: &[f64], y: f64) -> f64 {
    unimplemented!()
}
```
to
```
#[rustc_autodiff]
#[inline(never)]
pub fn f1(x: &[f64], y: f64) -> f64 {
    ::core::panicking::panic("not implemented")
}
#[rustc_autodiff(Reverse, Duplicated, Const, Active,)]
#[inline(never)]
pub fn df(x: &[f64], dx: &mut [f64], y: f64, dret: f64) -> f64 {
    unsafe { asm!("NOP"); };
    ::core::hint::black_box(f1(x, y));
    ::core::hint::black_box((dx, dret));
    ::core::hint::black_box(f1(x, y))
}
```
I will add a few more tests once I figured out why rustc rebuilds every time I touch a test.

Tracking:

- https://github.com/rust-lang/rust/issues/124509

try-job: dist-x86_64-msvc
2024-10-15 01:30:01 +00:00
Gabriel Bjørnager Jensen
3c31729887
Stabilise 'const_make_ascii' 2024-10-14 17:56:36 -07:00
Folkert de Vries
10aa255541 improve error messages for C-cmse-nonsecure-entry functions 2024-10-14 22:32:32 +02:00
George Bateman
4e438f7d6b
Fix two const-hacks 2024-10-14 20:50:40 +01:00
bors
9322d183f4 Auto merge of #131690 - matthiaskrgr:rollup-mcau4ol, r=matthiaskrgr
Rollup of 8 pull requests

Successful merges:

 - #129424 (Stabilize `Pin::as_deref_mut()`)
 - #131332 (Fix clobber_abi and disallow SVE-related registers in Arm64EC inline assembly)
 - #131384 (Update precondition tests (especially for zero-size access to null))
 - #131430 (Special treatment empty tuple when suggest adding a string literal in format macro.)
 - #131550 (Make some tweaks to extern block diagnostics)
 - #131667 (Fix AArch64InlineAsmReg::emit)
 - #131679 (compiletest: Document various parts of compiletest's `lib.rs`)
 - #131682 (Tag PRs affecting compiletest with `A-compiletest`)

Failed merges:

 - #131496 (Stabilise `const_make_ascii`.)

r? `@ghost`
`@rustbot` modify labels: rollup
2024-10-14 16:38:40 +00:00
Matthias Krüger
ac9b21281e
Rollup merge of #131682 - jieyouxu:compiletest-label, r=Zalathar
Tag PRs affecting compiletest with `A-compiletest`
2024-10-14 17:06:39 +02:00
Matthias Krüger
53cfc10742
Rollup merge of #131679 - Zalathar:ct-docs, r=jieyouxu
compiletest: Document various parts of compiletest's `lib.rs`

This adds some much-needed comments to many of the items in compiletest's `lib.rs`, giving a better overview of how a compiletest invocation actually proceeds.

To make review easier I have refrained from renames or functional changes, though I couldn't resist getting rid of one obviously-redundant `Arc::clone` in `make_test_closure`.
2024-10-14 17:06:39 +02:00
Matthias Krüger
dbb0581ff5
Rollup merge of #131667 - taiki-e:aarch64-inline-asm-reg-emit, r=Amanieu
Fix AArch64InlineAsmReg::emit

Currently, this method uses `self as u32 - Self::x0 as u32` to get register index:
36780360b6/compiler/rustc_target/src/asm/aarch64.rs (L204)

However, this is incorrect for reasons explained in the following comment:
36780360b6/compiler/rustc_codegen_llvm/src/asm.rs (L544-L549)

r? ``@Amanieu``

``@rustbot`` label O-AArch64 +A-inline-assembly
2024-10-14 17:06:38 +02:00
Matthias Krüger
b8cdca8cce
Rollup merge of #131550 - compiler-errors:extern-diags, r=spastorino
Make some tweaks to extern block diagnostics

Self-explanatory. See the diagnostic changes; I hope they make them a bit more descriptive.

r? spastorino
2024-10-14 17:06:38 +02:00
Matthias Krüger
75231f8764
Rollup merge of #131430 - surechen:fix_130495, r=jieyouxu
Special treatment empty tuple when suggest adding a string literal in format macro.

For example:
```rust
let s = "123";
println!({}, "sss", s);
```
Suggest:
`println!("{:?} {} {}", {}, "sss", s);`

fixes #130170
2024-10-14 17:06:37 +02:00
Matthias Krüger
32062b4b8e
Rollup merge of #131384 - saethlin:precondition-tests, r=ibraheemdev
Update precondition tests (especially for zero-size access to null)

I don't much like the current way I've updated the precondition check helpers, but I couldn't come up with anything better. Ideas welcome.

I've organized `tests/ui/precondition-checks` mostly with one file per function that has `assert_unsafe_precondition` in it, with revisions that check each precondition. The important new test is `tests/ui/precondition-checks/zero-size-null.rs`.
2024-10-14 17:06:36 +02:00
Matthias Krüger
43bf4f1fd3
Rollup merge of #131332 - taiki-e:arm64ec-clobber-abi, r=Amanieu
Fix clobber_abi and disallow SVE-related registers in Arm64EC inline assembly

Currently `clobber_abi` in Arm64EC inline assembly is implemented using `InlineAsmClobberAbi::AArch64NoX18`, but broken since it attempts to clobber registers that cannot be used in Arm64EC: https://godbolt.org/z/r3PTrGz5r

```
error: cannot use register `x13`: x13, x14, x23, x24, x28, v16-v31 cannot be used for Arm64EC
 --> <source>:6:14
  |
6 |     asm!("", clobber_abi("C"), options(nostack, nomem, preserves_flags));
  |              ^^^^^^^^^^^^^^^^

error: cannot use register `x14`: x13, x14, x23, x24, x28, v16-v31 cannot be used for Arm64EC
 --> <source>:6:14
  |
6 |     asm!("", clobber_abi("C"), options(nostack, nomem, preserves_flags));
  |              ^^^^^^^^^^^^^^^^

<omitted the same errors for v16-v31>
```

Additionally, this disallows SVE-related registers per https://github.com/rust-lang/rust/pull/131332#issuecomment-2401189142.

cc ``@dpaoliello``

r? ``@Amanieu``

``@rustbot`` label O-windows O-AArch64 +A-inline-assembly
2024-10-14 17:06:35 +02:00
Matthias Krüger
7ed6d1cd38
Rollup merge of #129424 - coolreader18:stabilize-pin_as_deref_mut, r=dtolnay
Stabilize `Pin::as_deref_mut()`

Tracking issue: closes #86918

Stabilizing the following API:

```rust
impl<Ptr: DerefMut> Pin<Ptr> {
    pub fn as_deref_mut(self: Pin<&mut Pin<Ptr>>) -> Pin<&mut Ptr::Target>;
}
```

I know that an FCP has not been started yet, but this isn't a very complex stabilization, and I'm hoping this can motivate an FCP to *get* started - this has been pending for a while and it's a very useful function when writing Future impls.

r? ``@jonhoo``
2024-10-14 17:06:35 +02:00
bors
17a19e684c Auto merge of #131672 - matthiaskrgr:rollup-gyzysj4, r=matthiaskrgr
Rollup of 8 pull requests

Successful merges:

 - #128967 (std::fs::get_path freebsd update.)
 - #130629 (core/net: add Ipv[46]Addr::from_octets, Ipv6Addr::from_segments.)
 - #131274 (library: Const-stabilize `MaybeUninit::assume_init_mut`)
 - #131473 (compiler: `{TyAnd,}Layout` comes home)
 - #131533 (emscripten: Use the latest emsdk 3.1.68)
 - #131593 (miri: avoid cloning AllocExtra)
 - #131616 (merge const_ipv4 / const_ipv6 feature gate into 'ip' feature gate)
 - #131660 (Also use outermost const-anon for impl items in `non_local_defs` lint)

r? `@ghost`
`@rustbot` modify labels: rollup
2024-10-14 12:20:35 +00:00
许杰友 Jieyou Xu (Joe)
9f42f9491d triagebot: tag PRs affecting compiletest with A-compiletest 2024-10-14 19:33:58 +08:00
Zalathar
cec5986439 Document various parts of compiletest's lib.rs 2024-10-14 21:09:48 +11:00
Matthias Krüger
d34b9324c0
Rollup merge of #131660 - Urgau:non_local_def-131643, r=jieyouxu
Also use outermost const-anon for impl items in `non_local_defs` lint

This PR update the logic for the impl paths (items) in the `non_local_definitions` lint to also consider const-anon in case the impl definition is wrapped inside const-anon it-self wrapped into a const-anon where the items are.

r? `@jieyouxu` *(since you interacted on the issue)*
Fixes *(after beta-backport)* #131643
2024-10-14 06:04:30 +02:00
Matthias Krüger
5d63a3db9c
Rollup merge of #131616 - RalfJung:const_ip, r=tgross35
merge const_ipv4 / const_ipv6 feature gate into 'ip' feature gate

https://github.com/rust-lang/rust/issues/76205 has been closed a while ago, but there are still some functions that reference it. Those functions are all unstable *and* const-unstable. There's no good reason to use a separate feature gate for their const-stability, so this PR moves their const-stability under the same gate as their regular stability, and therefore removes the remaining references to https://github.com/rust-lang/rust/issues/76205.
2024-10-14 06:04:29 +02:00
Matthias Krüger
4139018cfb
Rollup merge of #131593 - RalfJung:alloc-no-clone, r=saethlin
miri: avoid cloning AllocExtra

We shouldn't be cloning Miri allocations, so make `AllocExtra::clone` panic instead, and adjust the one case where we *do* clone (the leak check) to avoid cloning.

This is in preparation for https://github.com/rust-lang/miri/pull/3966 where I am adding something to `AllocExtra` that cannot (easily) be cloned.

r? ``@saethlin``
2024-10-14 06:04:29 +02:00
Matthias Krüger
eb060f6507
Rollup merge of #131533 - workingjubilee:update-emscripten-version, r=Kobzol
emscripten: Use the latest emsdk 3.1.68

This should fix our precompiled std being unsound in `std::fs` code.

Should resolve #131467 I hope.
2024-10-14 06:04:28 +02:00
Matthias Krüger
cb140dcb00
Rollup merge of #131473 - workingjubilee:move-that-abi-up, r=saethlin
compiler: `{TyAnd,}Layout` comes home

The `Layout` and `TyAndLayout` types are heavily abstract and have no particular target-specific qualities, though we do use them to answer questions particular to targets. We can keep it that way if we simply move them out of `rustc_target` and into `rustc_abi`. They bring a small entourage of connected types with them, but that's fine.

This will allow us to strengthen a few abstraction barriers over time and thus make the notoriously gnarly layout code easier to refactor. For now, we don't need to worry about that and deliberately use reexports to minimize this particular diff.
2024-10-14 06:04:28 +02:00
Matthias Krüger
cc5d86ac60
Rollup merge of #131274 - workingjubilee:stabilize-the-one-that-got-away, r=scottmcm
library: Const-stabilize `MaybeUninit::assume_init_mut`

FCP completed in https://github.com/rust-lang/rust/issues/86722#issuecomment-2393954459

Also moves const-ness of an unstable fn under the `maybe_uninit_slice` gate, Cc https://github.com/rust-lang/rust/issues/63569
2024-10-14 06:04:27 +02:00
Matthias Krüger
e01eae72da
Rollup merge of #130629 - Dirbaio:net-from-octets, r=tgross35
core/net: add Ipv[46]Addr::from_octets, Ipv6Addr::from_segments.

Adds:

- `Ipv4Address::from_octets([u8;4])`
- `Ipv6Address::from_octets([u8;16])`
- `Ipv6Address::from_segments([u16;8])`

equivalent to the existing `From` impls.

Advantages:

- Consistent with `to_bits, from_bits`.
- More discoverable than the `From` impls.
- Helps with type inference: it's common to want to convert byte slices to IP addrs. If you try this

```rust
fn foo(x: &[u8]) -> Ipv4Addr {
   Ipv4Addr::from(foo.try_into().unwrap())
}
```

it [doesn't work](https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=0e2873312de275a58fa6e33d1b213bec). You have to write `Ipv4Addr::from(<[u8;4]>::try_from(x).unwrap())` instead, which is not great. With `from_octets` it is able to infer the right types.

Found this while porting [smoltcp](https://github.com/smoltcp-rs/smoltcp/) from its own IP address types to the `core::net` types.

~~Tracking issues #27709 #76205~~
Tracking issue: https://github.com/rust-lang/rust/issues/131360
2024-10-14 06:04:27 +02:00
Matthias Krüger
55f8b9e7d8
Rollup merge of #128967 - devnexen:get_path_fbsd_upd, r=joboet
std::fs::get_path freebsd update.

what matters is we re doing the right things as doing sizeof, rather than passing KINFO_FILE_SIZE (only defined on intel architectures), the kernel
 making sure it matches the expectation in its side.
2024-10-14 06:04:26 +02:00
bors
f6648f252a Auto merge of #126557 - GrigorenkoPV:vec_track_caller, r=joboet
Add `#[track_caller]` to allocating methods of `Vec` & `VecDeque`

Part 4 in a lengthy saga.
r? `@joshtriplett` because they were the reviewer the last 3 times.
`@bors` rollup=never "[just in case this has perf effects, Vec is hot](https://github.com/rust-lang/rust/pull/79323#issuecomment-731866746)"

This was first attempted in #79323 by `@nvzqz.` It got approval from `@joshtriplett,` but rotted with merge conflicts and got closed.

Then it got picked up by `@Dylan-DPC-zz` in #83359. A benchmark was run[^perf], the results (after a bit of thinking[^thinking]) were deemed ok[^ok], but there was a typo[^typo] and the PR was made from a wrong remote in the first place[^remote], so #83909 was opened instead.

By the time #83909 rolled around, the methods in question had received some optimizations[^optimizations], so another perf run was conducted[^perf2]. The results were ok[^ok2]. There was a suggestion to add regression tests for panic behavior [^tests], but before it could be addressed, the PR fell victim to merge conflicts[^conflicts] and died again[^rip].

3 years have passed, and (from what I can tell) this has not been tried again, so here I am now, reviving this old effort.

Given how much time has passed and the fact that I've also touched `VecDeque` this time, it probably makes sense to
`@bors` try `@rust-timer`

[^perf]: https://github.com/rust-lang/rust/pull/83359#issuecomment-804450095
[^thinking]: https://github.com/rust-lang/rust/pull/83359#issuecomment-805286704
[^ok]: https://github.com/rust-lang/rust/pull/83359#issuecomment-812739031
[^typo]: https://github.com/rust-lang/rust/pull/83359#issuecomment-812750205
[^remote]: https://github.com/rust-lang/rust/pull/83359#issuecomment-814067119
[^optimizations]: https://github.com/rust-lang/rust/pull/83909#issuecomment-813736593
[^perf2]: https://github.com/rust-lang/rust/pull/83909#issuecomment-813825552
[^ok2]: https://github.com/rust-lang/rust/pull/83909#issuecomment-813831341
[^tests]: https://github.com/rust-lang/rust/pull/83909#issuecomment-825788964
[^conflicts]: https://github.com/rust-lang/rust/pull/83909#issuecomment-851173480
[^rip]: https://github.com/rust-lang/rust/pull/83909#issuecomment-873569771
2024-10-14 02:33:40 +00:00
surechen
ceced5322c Special treatment empty tuple when suggest adding a string literal in format macro.
For example:
```rust
let s = "123";
println!({}, "sss", s);
```
Suggest:
`println!("{:?} {} {}", {}, "sss", s);`

fixes #130170
2024-10-14 10:07:57 +08:00
bors
5ceb623a4a Auto merge of #131662 - matthiaskrgr:rollup-r1wkfxw, r=matthiaskrgr
Rollup of 8 pull requests

Successful merges:

 - #130356 (don't warn about a missing change-id in CI)
 - #130900 (Do not output () on empty description)
 - #131066 (Add the Chinese translation entry to the RustByExample build process)
 - #131067 (Fix std_detect links)
 - #131644 (Clean up some Miri things in `sys/windows`)
 - #131646 (sys/unix: add comments for some Miri fallbacks)
 - #131653 (Remove const trait bound modifier hack)
 - #131659 (enable `download_ci_llvm` test)

r? `@ghost`
`@rustbot` modify labels: rollup
2024-10-13 22:38:44 +00:00
Taiki Endo
67ebb6c20b Fix AArch64InlineAsmReg::emit 2024-10-14 06:04:07 +09:00
Taiki Endo
d858dfedbb Fix clobber_abi and disallow SVE-related registers in Arm64EC inline assembly 2024-10-14 05:30:45 +09:00
bors
27861c429a Auto merge of #131560 - cuviper:start-1.84, r=cuviper
Bump to 1.84

https://forge.rust-lang.org/release/process.html#bump-the-stable-version-number-t-6-days-friday-the-week-before

r? ghost
2024-10-13 20:08:57 +00:00
Dario Nieuwenhuis
0b7e39908e core/net: use hex for ipv6 doctests for consistency. 2024-10-13 20:27:24 +02:00
Dario Nieuwenhuis
725d1f7905 core/net: add Ipv[46]Addr::from_octets, Ipv6Addr::from_segments 2024-10-13 20:26:23 +02:00
Matthias Krüger
0e00a70e52
Rollup merge of #131659 - onur-ozkan:llvm-test, r=albertlarsan68
enable `download_ci_llvm` test

This was ignored because it caused merge failures on [LLVM update PR](https://github.com/rust-lang/rust/pull/131448). The issue was not checking `is_ci_llvm_available` in the test which is crucial for enabling CI LLVM:

2aa26d8a72/src/bootstrap/src/core/config/config.rs (L2835-L2844)
2024-10-13 18:27:22 +02:00
Matthias Krüger
20add51856
Rollup merge of #131653 - compiler-errors:no-modifier-hack, r=fee1-dead
Remove const trait bound modifier hack

It's no longer necessary, according to the test suite :D

r? `@fee1-dead` or anyone really
2024-10-13 18:27:22 +02:00
Matthias Krüger
b9651d00d4
Rollup merge of #131646 - RalfJung:unix-miri-fallbacks, r=joboet
sys/unix: add comments for some Miri fallbacks
2024-10-13 18:27:21 +02:00
Matthias Krüger
9c5b4460dd
Rollup merge of #131644 - RalfJung:win-miri, r=joboet
Clean up some Miri things in `sys/windows`

- remove miri hack that is only needed for win7 (we don't support win7 as a target in Miri)
- remove outdated comment now that Miri is on CI
2024-10-13 18:27:21 +02:00
Matthias Krüger
6bca11ec38
Rollup merge of #131067 - ismailarilik:fix-std-detect-links, r=albertlarsan68
Fix std_detect links

This PR aims to fix this issue: https://github.com/rust-lang/rust/issues/96506

Fixes #96506
2024-10-13 18:27:20 +02:00
Matthias Krüger
05a29714c5
Rollup merge of #131066 - Binlogo:build-doc/rbe-add-zh-entry, r=albertlarsan68
Add the Chinese translation entry to the RustByExample build process

Following the guidelines outlined at [https://github.com/rust-lang/rust-by-example/blob/master/TRANSLATING.md](https://github.com/rust-lang/rust-by-example/blob/master/TRANSLATING.md), I am adding a Chinese translation to Rust by Example. You can view the related pull request here: [https://github.com/rust-lang/rust-by-example/pull/1886#issue-2537891289](https://github.com/rust-lang/rust-by-example/pull/1886#issue-2537891289).

For similar issues and PRs, see [https://github.com/rust-lang/rust/issues/124641](https://github.com/rust-lang/rust/issues/124641) and [https://github.com/rust-lang/rust/pull/124731](https://github.com/rust-lang/rust/pull/124731).
2024-10-13 18:27:20 +02:00
Matthias Krüger
022b327d86
Rollup merge of #130900 - capickett:empty-description-rust-version, r=albertlarsan68
Do not output () on empty description

When passing an explicitly empty description string, as explained here https://github.com/rust-lang/rust/blob/master/config.example.toml#L611-L613, my expectation is that the resulting rustc will be compatible with upstream.

However, it seems that instead, a `()` is added to the end of the version string, causing the version compatibility check to fail. My proposed fix here would be to instead only print `({description})` if `description` is a non-empty string.
2024-10-13 18:27:19 +02:00
Matthias Krüger
1d0c7cf49f
Rollup merge of #130356 - lolbinarycat:ci-no-change-id, r=albertlarsan68
don't warn about a missing change-id in CI

fixes #130352
2024-10-13 18:27:19 +02:00
Urgau
b5e91a00c8 Also use outermost const-anon for impl items in non_local_defs lint 2024-10-13 18:14:29 +02:00