Jonathan M Davis:

What would that even mean? The only thing that $ is used for is for representing the length of the array in an indexing or slicing operation. That statement is trying to use it in a declaration, which is nonsensical.

It's not nonsensical, it's a new tiny feature. It means the lenght of x is statically determined by the literal. So this:

int[$] x=[1,2,3];

means:

int[3] x=[1,2,3];

But this is not a breaking change, it's just an additive change, so it's not urgent.

Bye,
bearophile

Reply via email to