Zend certified PHP/Magento developer

What are your thoughts about DS Collections and other variable types?

Arrays in PHP are fantastic. You can do everything and the kitchen sink with them.

However, sometimes that can bite you and you would want more specific collection types.

I am finding DS collections a pleasure to work with, but there are a couple of questions lurking at the back of my head.

  1. Why are DS collections not part of the core extensions?
  2. Has including DS in core been considered?
  3. If not, does this mean that it is at more risk of being abandoned?

A bit off topic, but I have a personal wish list for PHP 8 but I am curious if any of the following has been considered for PHP 8.x:

  1. Type checking array elements, or just give me
  2. Structs

and I would love getting

  1. Enums
  2. Support for methods on primitives

I am curious to learn what others’ thoughts are 🙂

submitted by /u/darkhorz
[link] [comments]