3v4l.org

run code in 300+ PHP versions simultaneously
<?php $begin = new \DateTime('13/10/2015'); $end = new \DateTime('15/10/2015'); echo $begin->diff($end)->days;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/LBRDG
function name:  (null)
number of ops:  14
compiled vars:  !0 = $begin, !1 = $end
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   NEW                                              $2      'DateTime'
          1        SEND_VAL_EX                                              '13%2F10%2F2015'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $2
    3     4        NEW                                              $5      'DateTime'
          5        SEND_VAL_EX                                              '15%2F10%2F2015'
          6        DO_FCALL                                      0          
          7        ASSIGN                                                   !1, $5
    5     8        INIT_METHOD_CALL                                         !0, 'diff'
          9        SEND_VAR_EX                                              !1
         10        DO_FCALL                                      0  $8      
         11        FETCH_OBJ_R                                      ~9      $8, 'days'
         12        ECHO                                                     ~9
         13      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
166.25 ms | 1397 KiB | 13 Q