braceless with statements

Dennis dkorpel at gmail.com
Fri Nov 12 11:05:54 UTC 2021


On Friday, 12 November 2021 at 10:55:21 UTC, Stefan Koch wrote:
> It is a really simple patch and I think it's worthwhile to have 
> this in the main language.

How about other statements, like `if`, `for`, `foreach`, 
`switch`? When extending `attribute:` syntax to statements, might 
as well include all of them for consistency. N.b. this is already 
allowed in global scope:
```D
static if (true):
```
Not in function scope though.


More information about the Digitalmars-d mailing list