3v4l.org

run code in 300+ PHP versions simultaneously
<?php function someFunc($a){ var_dump($a); throw new Exception('blaaaaaaaaaaaaaah'); }; function tryCatch($callable, ...$args){ try{ return $callable(...$args); }catch(Exception $e){ return null; //hehehe he he heh we do nothing what you gonna do he he } } tryCatch('someFunc','jjj');

preferences:
82.48 ms | 402 KiB | 5 Q