Can you tell me what in PHP 8 you're struggling with? Pretty much everything listed here has been deprecated for a long time or used by almost nobody: https://www.php.net/manual/en/migration80.incompatible.php
I've made my whole career about PHP and had no idea it supported stuff like (uncast).