Skip to content

Unexpected shadow label warning #81799

Description

This code produces the warning:

fn main() {
    if true {
        'a: loop {
            break 'a;
        }
    } else {
        'a: loop {
            break 'a;
        }
    }
}

Playground link.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-diagnosticsArea: Messages for errors, warnings, and lintsA-lintsArea: Lints (warnings about flaws in source code) such as unused_mut.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions