Skip to content

"Unwrap block" handles unsafe wrongly #17964

Closed
@ChayimFriedman2

Description

@ChayimFriedman2

This has bothered me for a long time, so finally I'm reporting it.

If you have an unsafe { } block and you activate the assist "Unwrap block" on it, it removes the closing } and the u but leaves the nsafe {, leading to invalid code.

Screen.Recording.2024-08-26.045535.mp4

rust-analyzer version: rust-analyzer version: 0.3.2078-standalone (fa00326 2024-08-17)

rustc version: rustc 1.80.1 (3f5fd8dd4 2024-08-06)

editor or extension: VSCode

relevant settings: None

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions