diff options
| author | bors <bors@rust-lang.org> | 2024-07-01 10:20:01 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2024-07-01 10:20:01 +0000 |
| commit | 29fbc2414d63e985a0fb1547489bf2fb3b093a78 (patch) | |
| tree | e9b8b6c6c868c3873c07ad841b62a57089094c3c /library/std/src/sys/pal/unix/stack_overflow.rs | |
| parent | dffbad50c1d8bbd92dacac89222f4832f7d518a7 (diff) | |
| parent | 742c2ea6217067b69ea82b12cdbdd0c1ee6d4c09 (diff) | |
| download | rust-29fbc2414d63e985a0fb1547489bf2fb3b093a78.tar.gz rust-29fbc2414d63e985a0fb1547489bf2fb3b093a78.zip | |
Auto merge of #17494 - harrysarson:harry/keep-braces, r=Veykril
do not normalize `use foo::{self}` to `use foo`
It changes behaviour and can cause collisions. E.g. for the following snippet
```rs
mod foo {
pub mod bar {}
pub const bar: i32 = 8;
}
// transforming the below to `use foo::bar;` causes the error:
//
// the name `bar` is defined multiple times
use foo::bar::{self};
const bar: u32 = 99;
fn main() {
let local_bar = bar;
}
```
we still normalize
```rs
use foo::bar;
use foo::bar::{self};
```
to `use foo::bar;` because this cannot cause collisions.
See: https://github.com/rust-lang/rust-analyzer/pull/17140#issuecomment-2079189725
Diffstat (limited to 'library/std/src/sys/pal/unix/stack_overflow.rs')
0 files changed, 0 insertions, 0 deletions
