PHP-CSS-Parser icon indicating copy to clipboard operation
PHP-CSS-Parser copied to clipboard

Refactor the array combination functions in `CSSBlockList` using `array_push`

Open oliverklee opened this issue 1 year ago • 3 comments

… and the splat operator.

https://www.php.net/manual/en/function.array-push.php

We might need to raise the minimum PHP version first.

oliverklee avatar Feb 26 '25 21:02 oliverklee

… and the splat operator.

We might need to raise the minimum PHP version first.

PHP 7.2 is the minimum version in the main branch; this supports most splattable features, including being able to specify strict types. I don't expect we would need 'first class callables', which require PHP 8.1, and would I think be a bump too far. Some good information in answers here: https://stackoverflow.com/questions/41124015/what-is-the-meaning-of-three-dots-in-php.

JakeQZ avatar Feb 26 '25 22:02 JakeQZ

We'll need at least PHP 7.3 for this - in #1045, the 7.2 unit tests are failing.

oliverklee avatar Mar 03 '25 10:03 oliverklee

We'll need at least PHP 7.3 for this - in #1045, the 7.2 unit tests are failing.

This is presumably for array_push to be called with only one argument.

JakeQZ avatar Mar 03 '25 12:03 JakeQZ