3 ms·
I too dislike PHP, but this is one of the things I hate the most: this is like conflating addition and multiplication of types. Arrays and maps have separate us
by ashton314 6y ago
I too dislike PHP, but this is one of the things I hate the most: this is like conflating addition and multiplication of types. Arrays and maps have separate use cases and very different trade-offs and PHP gives you no choice in the matter.
- tottenhm 6y agoIn fairness, it does give choices -- https://www.php.net/manual/en/spl.datastructures.php https://www.php.net/manual/en/spl.datastructures.php
- duskwuff 6y agoThe SPL data structures are widely considered a mistake. They're awkwardly designed, cannot be type-hinted, and often perform worse than pure-PHP alternatives.