https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118718

            Bug ID: 118718
           Summary: bogus -Wvexing-parse with trailing-return-type
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: mpolacek at gcc dot gnu.org
  Target Milestone: ---

```
void
fn ()
{
  auto f () -> auto;
}
```

emits

q.C: In function ‘void fn()’:
q.C:4:10: warning: empty parentheses were disambiguated as a function
declaration [-Wvexing-parse]
    4 |   auto f () -> auto;
      |          ^~

but it can't be a variable due to the trailing-return-type.

Reply via email to