Skip to content

Conversation

@A4-Tacks
Copy link
Member

@A4-Tacks A4-Tacks commented Nov 15, 2025

Close #18049

Example

mod std { pub mod fmt { pub trait Debug {} } }
fn main() {
    $0std::fmt::Debug;
    let x: std::fmt::Debug = std::fmt::Debug;
}

Before this PR

use std::fmt;

mod std { pub mod fmt { pub trait Debug {} } }
fn main() {
    fmt::Debug;
    let x: fmt::Debug = fmt::Debug;
}

After this PR

use std::fmt::Debug;

mod std { pub mod fmt { pub trait Debug {} } }
fn main() {
    Debug;
    let x: Debug = Debug;
}

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Nov 15, 2025
Example
---
```rust
mod std { pub mod fmt { pub trait Debug {} } }
fn main() {
    $0std::fmt::Debug;
    let x: std::fmt::Debug = std::fmt::Debug;
}
```

**Before this PR**

```rust
use std::fmt;

mod std { pub mod fmt { pub trait Debug {} } }
fn main() {
    fmt::Debug;
    let x: fmt::Debug = fmt::Debug;
}
```

**After this PR**

```rust
use std::fmt::Debug;

mod std { pub mod fmt { pub trait Debug {} } }
fn main() {
    Debug;
    let x: Debug = Debug;
}
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

"Import qualified name" should work on the first segment of a path

2 participants