3v4l.org

run code in 500+ PHP versions simultaneously
<?php set_error_handler(function() { echo 'Error handler executed' . PHP_EOL; return null; }); trigger_error(E_ERROR); echo PHP_EOL; echo PHP_EOL; echo "hello"; echo PHP_EOL; echo 'Now with return false:'; echo PHP_EOL; set_error_handler(function() { echo 'Error handler executed' . PHP_EOL; return false; }); trigger_error(E_ERROR); echo "hello";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/rSesI
function name:  (null)
number of ops:  22
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                                   'set_error_handler'
          1        DECLARE_LAMBDA_FUNCTION                              ~0      [0]
    7     2        SEND_VAL                                                     ~0
    3     3        DO_ICALL                                                     
    9     4        INIT_FCALL                                                   'trigger_error'
          5        SEND_VAL                                                     1
          6        DO_ICALL                                                     
   10     7        ECHO                                                         '%0A'
   11     8        ECHO                                                         '%0A'
   12     9        ECHO                                                         'hello'
   13    10        ECHO                                                         '%0A'
   14    11        ECHO                                                         'Now+with+return+false%3A'
   15    12        ECHO                                                         '%0A'
   17    13        INIT_FCALL                                                   'set_error_handler'
         14        DECLARE_LAMBDA_FUNCTION                              ~3      [1]
   21    15        SEND_VAL                                                     ~3
   17    16        DO_ICALL                                                     
   23    17        INIT_FCALL                                                   'trigger_error'
         18        SEND_VAL                                                     1
         19        DO_ICALL                                                     
   25    20        ECHO                                                         'hello'
         21      > RETURN                                                       1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/rSesI
function name:  {closure:/in/rSesI:3}
number of ops:  3
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    4     0  E >   ECHO                                                         'Error+handler+executed%0A'
    6     1      > RETURN                                                       null
    7     2*     > RETURN                                                       null

End of Dynamic Function 0

Dynamic Function 1
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/rSesI
function name:  {closure:/in/rSesI:17}
number of ops:  3
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   18     0  E >   ECHO                                                         'Error+handler+executed%0A'
   20     1      > RETURN                                                       <false>
   21     2*     > RETURN                                                       null

End of Dynamic Function 1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
170.01 ms | 2271 KiB | 15 Q