[clang] label diagnosed as unused when used with break and/or continue (C2Y named loop) (original) (raw)

Skip to content

Sign in

Appearance settings

View all features

View all solutions

Provide feedback

We read every piece of feedback, and take your input very seriously.

Include my email address so I can be contacted

Saved searches

Use saved searches to filter your results more quickly

Sign in

Sign up

Appearance settings

llvm / llvm-project Public

Additional navigation options

New issue

New issue

Closed

#166033

Closed

[clang] label diagnosed as unused when used with break and/or continue (C2Y named loop)

#166013

#166033

Labels

c2yclang:diagnosticsNew/improved warning or error message in Clang, but not in clang-tidy or static analyzerconfirmedVerified by a second party

@olemayu

Description

@olemayu

olemayu

opened

on Nov 1, 2025

https://godbolt.org/z/9bE1Yv4s9

loop: // warning: unused label 'loop' [-Wunused-label] while (true) { Event event;

while (PollEvent(&event)) {
    if (event.type == EVENT_QUIT) {
        break loop;
    }
}

}

Metadata

Metadata

Assignees

No one assigned

Labels

c2yclang:diagnosticsNew/improved warning or error message in Clang, but not in clang-tidy or static analyzerconfirmedVerified by a second party

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions