3v4l.org

run code in 500+ PHP versions simultaneously
<?php class hola { /** * Limita la cantidad correcta de * parametros de una action * * @var bool */ public bool $limit_params = true; } class hi { public $limit_params = false; } var_dump((new hi))->limit_params;
Output for 8.0.1 - 8.0.30, 8.1.0 - 8.1.34, 8.2.0 - 8.2.34, 8.3.0 - 8.3.35, 8.4.1 - 8.4.26, 8.5.0 - 8.5.11
object(hi)#1 (1) { ["limit_params"]=> bool(false) } Warning: Attempt to read property "limit_params" on null in /in/TQeCe on line 18
Output for 7.4.0 - 7.4.33
object(hi)#1 (1) { ["limit_params"]=> bool(false) } Notice: Trying to get property 'limit_params' of non-object in /in/TQeCe on line 18

preferences:
34.71 ms | 1140 KiB | 9 Q