https://issues.dlang.org/show_bug.cgi?id=19730

          Issue ID: 19730
           Summary: if (auto x) {} isn't properly rejected
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: minor
          Priority: P1
         Component: dmd
          Assignee: [email protected]
          Reporter: [email protected]

```
void func() {
  bool x;
  if (auto x) {}
}
```
This is accepted as valid code, but it should not be. It is currently treated
as if the auto is not present.

The last version to correctly reject this was DMD 2.062.

--

Reply via email to