3v4l.org

run code in 300+ PHP versions simultaneously
<?php $period = new DatePeriod(new DateTimeImmutable("now"), new DateInterval("P2Y4DT6H8M"), 2); var_dump($period->getStartDate()); var_dump($period->getEndDate()); // segfault? Nice.
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/a044v
function name:  (null)
number of ops:  23
compiled vars:  !0 = $period
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $1      'DatePeriod'
          1        NEW                                              $2      'DateTimeImmutable'
          2        SEND_VAL_EX                                              'now'
          3        DO_FCALL                                      0          
          4        SEND_VAR_NO_REF_EX                                       $2
          5        NEW                                              $4      'DateInterval'
          6        SEND_VAL_EX                                              'P2Y4DT6H8M'
          7        DO_FCALL                                      0          
          8        SEND_VAR_NO_REF_EX                                       $4
          9        SEND_VAL_EX                                              2
         10        DO_FCALL                                      0          
         11        ASSIGN                                                   !0, $1
    5    12        INIT_FCALL                                               'var_dump'
         13        INIT_METHOD_CALL                                         !0, 'getStartDate'
         14        DO_FCALL                                      0  $8      
         15        SEND_VAR                                                 $8
         16        DO_ICALL                                                 
    6    17        INIT_FCALL                                               'var_dump'
         18        INIT_METHOD_CALL                                         !0, 'getEndDate'
         19        DO_FCALL                                      0  $10     
         20        SEND_VAR                                                 $10
         21        DO_ICALL                                                 
    8    22      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
148.44 ms | 992 KiB | 14 Q