You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
immutableint[5] x = [1, 2, 3, 4, 5]; // <-- this compilesimmutableint[5] x = [1, 2, 3, 4, 5, 6]; // <-- this does not...immutableint[5] x = [1, 2, 3, 4]; // <-- this compiles (!!!) excusemewtf?!
I'm sure this is un-changeable, but can we please get a warning for this?
I reeeeeallly want this to be something that doesn't silently slip through the cracks!
It wouldn't be such a problem if we could write int[$] = [1,2,3,4];, but since we can't do that, this is almost certainly a bug at every location.
I just searched through my code for cases of this (I have a lot of tables), and found 3 actual real cases of actual bugs from this. (!)