scrivo / highlight.php

A port of highlight.js by Ivan Sagalaev to PHP
BSD 3-Clause "New" or "Revised" License
695 stars 45 forks source link

PHP 8.1 compatible #93

Closed phpfui closed 2 years ago

phpfui commented 2 years ago

PHP 8.1 needs #[\ReturnTypeWillChange] on classes that implement \ArrayAccess, \Countable, or \IteratorAggregate

As this is a comment in pre 8.1 versions, it is completely backward compatible. In PHP 8.1, it prevents a depreciation notice.

It would be nice to merge quickly, as I use the dev-master version (V9 is too messed up to be usable due to bad autoloading that we fixed a while back).

Thanks!

phpfui commented 2 years ago

Can we just merge this? Complete no brainer. Merge and go!