3v4l.org

run code in 300+ PHP versions simultaneously
<?php $diff = date_create()->diff(date_create('-2 years')); print_r($diff);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Iofsa
function name:  (null)
number of ops:  13
compiled vars:  !0 = $diff
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'date_create'
          1        DO_ICALL                                         $1      
          2        INIT_METHOD_CALL                                         $1, 'diff'
          3        INIT_FCALL                                               'date_create'
          4        SEND_VAL                                                 '-2+years'
          5        DO_ICALL                                         $2      
          6        SEND_VAR_NO_REF_EX                                       $2
          7        DO_FCALL                                      0  $3      
          8        ASSIGN                                                   !0, $3
    4     9        INIT_FCALL                                               'print_r'
         10        SEND_VAR                                                 !0
         11        DO_ICALL                                                 
         12      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
167.77 ms | 1394 KiB | 17 Q