Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removing all unused imports removes used import #18941

Open
justanotheranonymoususer opened this issue Jan 15, 2025 · 0 comments
Open

Removing all unused imports removes used import #18941

justanotheranonymoususer opened this issue Jan 15, 2025 · 0 comments
Labels
A-assists C-bug Category: bug

Comments

@justanotheranonymoususer

rust-analyzer version: 0.3.2264-standalone (8364ef2 2025-01-12) [c:\Users\User.vscode\extensions\rust-lang.rust-analyzer-0.3.2264-win32-x64\server\rust-analyzer.exe]

rustc version: rustc 1.83.0 (90b35a623 2024-11-26)

editor or extension: VSCode w rust-analyzer v0.3.2264

relevant settings: (eg. client settings, or environment variables like CARGO, RUSTC, RUSTUP_HOME or CARGO_HOME)

repository link (if public, optional): (eg. rust-analyzer)

code snippet to reproduce:

use std::{
    io::Write,
    str,
};

fn greet(msg: &str) {
    println!("{msg}");
}

fn main() {
    greet(str::from_utf8(b"Hello, world!").unwrap());
}
Code.mp4
@justanotheranonymoususer justanotheranonymoususer added the C-bug Category: bug label Jan 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-assists C-bug Category: bug
Projects
None yet
Development

No branches or pull requests

2 participants