Fixing C's Biggest Mistake

Dom DiSc dominikus at scherkl.de
Thu Jan 5 09:07:57 UTC 2023


On Wednesday, 21 December 2022 at 19:31:22 UTC, Walter Bright 
wrote:
> My proposal for C:
>
>     int a[5] = { 0, 1, 2, 3, 4};
>     int p[..] = a;  // p points to 5 elements.

I would wish you first implement this for D:

```d
uint[] x = [1,2,3]; // create a dynamic array with initial size 3
uint[..] y = [1,2,3]; // create a static array with automatic 
size (not possible now)
```



More information about the Digitalmars-d mailing list