3v4l.org

run code in 300+ PHP versions simultaneously
<?php function test(int $test) { echo $test . "\n"; } //test('test'); // type error //test('123test'); // type error test(123.00); test(123.123); // deprecation warning test(true); test(false); //test(null); // type error test(123); //test([1]); // type error

This is an error 500

Value for `_results` contains invalid data `array`


preferences:
154.29 ms | 1674 KiB | 14 Q