Note, sorry but this article is going to skip between languages a bit. If you work in PHP, you likely know what they do and how to use them…

What prompted this article is that I was just working on a “function stack” of anonymous that other processes can add to, and I used this because of the “You can’t add to an array inside a foreach” issue; and a colleague saw it and said “what the devil is that?!?”

This stems from the fact that foreach grabs the key of “last” to compare to for its loop.

So many of its structures correspond to assembly in ways that should have made it really easy to make it run fast.
Newsletter

Get the latest Laravel/PHP jobs, events and curated articles straight to your inbox, once a week

Glimpse streamlines Laravel development by seamlessly deploying GitHub pull requests to preview environments with the help of Laravel Forge. Glimpse streamlines Laravel development by seamlessly deploying GitHub pull requests to preview environments with the help of Laravel Forge.
Fathom Analytics | Fast, simple and privacy-focused website analytics. Fathom Analytics | Fast, simple and privacy-focused website analytics.
Shirts painstakingly handcrafted by under-caffeinated developers. Shirts painstakingly handcrafted by under-caffeinated developers.
Community Partners