3v4l.org

run code in 300+ PHP versions simultaneously
<?php $var1 = "1"; $var2 = "2"; $temp1 = "var" . "1"; $temp2 = "var" . "2"; var_dump($($temp1) ?? $($temp2));
Output for 5.4.0 - 5.4.45, 5.5.24 - 5.5.30, 5.6.8 - 5.6.14
Parse error: syntax error, unexpected '(', expecting variable (T_VARIABLE) or '$' in /in/gqvrT on line 7
Process exited with code 255.

preferences:
187.37 ms | 1400 KiB | 66 Q