Skip to content

Format block with label #2722

@topecongiro

Description

@topecongiro

For example,

'empty_block: {}

let result = 'block: {
    if foo() {
        break 'block 1;
    }
    if bar() {
        break 'block 2;
    }
    3
};

cc https://github.com/rust-lang/rfcs/blob/master/text/2046-label-break-value.md.

Metadata

Metadata

Assignees

No one assigned

    Labels

    good first issueIssues up for grabs, also good candidates for new rustfmt contributors

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions