PHP 8.3 breaking change on arrays
HTML-код
- Опубликовано: 13 сен 2024
- This is the " Negative indices in arrays" segment from my "What's new in PHP 8.3 " livestream. Watch the full livestream here: www.youtube.co....
----------------------------------------------------------------------------------------------------
- Twitter: / enunomaduro
- Telegram Group: t.me/+RoAqqaaS...
- Threads: www.threads.ne...
- Mastodon: mastodon.socia...
- LinkedIn: / nunomaduro
- RUclips: / nunomaduro
- GitHub: github.com/nun...
- Bluesky: bsky.app/profi...
- Tiktok: / enunomaduro
Truly a PHP moment right there
ahah, for real.
Hey man!
Thank you for everything you do to PHP community!
Appreciate your effort!
My pleasure!
Thats an amazing changes for php. Love That.
Nice thanks for the information! Today i also learned about negative indexes! :)
Any scalar value can be an index (which is different from the internal index)
👍
🎉🎉
the whole thing is weird, I which indexes were just unsigned integers only and negatif integers used to start indexing starting from the end. f.e. $array[-1] being used to access the last element and $array[ - $array_size ] to access the first element.
XDD