Re:Avoid PHP trap
by randallsquared on Saturday July 05, 2008 @07:04PM
(#237391)
If creating a new language that looked like PHP/C/Java/etc, you could use {} for both blocks and arrays (and assoc arrays, like PHP) by making blocks a special case of arrays, conceptually. Then {0; 1; 2; 3;} would be an array of four elements, and as a bonus it would free up [] for something else. :)
[ Parent
| on HN ]