3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Test { public $a = 'a', protected $b = 'b'; private $c = 'c'; } var_export((array) new \Test());
Output for 7.1.17
Parse error: syntax error, unexpected 'protected' (T_PROTECTED), expecting variable (T_VARIABLE) in /in/h9PWp on line 6
Process exited with code 255.

preferences:
159.25 ms | 1394 KiB | 8 Q