3v4l.org

run code in 300+ PHP versions simultaneously
<?php $start_date = "2017-03-27"; $end_date = "2017-03-30"; $start = new DateTime($start_date); $end = new DateTime($end_date); while ($start < $end) { echo $start->format("Y-m-d")."\n"; $start->modify("+1 day"); }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 19
Branch analysis from position: 19
2 jumps found. (Code = 44) Position 1 = 21, Position 2 = 11
Branch analysis from position: 21
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 11
2 jumps found. (Code = 44) Position 1 = 21, Position 2 = 11
Branch analysis from position: 21
Branch analysis from position: 11
filename:       /in/Hu2EF
function name:  (null)
number of ops:  22
compiled vars:  !0 = $start_date, !1 = $end_date, !2 = $start, !3 = $end
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '2017-03-27'
    4     1        ASSIGN                                                   !1, '2017-03-30'
    6     2        NEW                                              $6      'DateTime'
          3        SEND_VAR_EX                                              !0
          4        DO_FCALL                                      0          
          5        ASSIGN                                                   !2, $6
    7     6        NEW                                              $9      'DateTime'
          7        SEND_VAR_EX                                              !1
          8        DO_FCALL                                      0          
          9        ASSIGN                                                   !3, $9
    9    10      > JMP                                                      ->19
   10    11    >   INIT_METHOD_CALL                                         !2, 'format'
         12        SEND_VAL_EX                                              'Y-m-d'
         13        DO_FCALL                                      0  $12     
         14        CONCAT                                           ~13     $12, '%0A'
         15        ECHO                                                     ~13
   11    16        INIT_METHOD_CALL                                         !2, 'modify'
         17        SEND_VAL_EX                                              '%2B1+day'
         18        DO_FCALL                                      0          
    9    19    >   IS_SMALLER                                               !2, !3
         20      > JMPNZ                                                    ~15, ->11
   12    21    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.44 ms | 1069 KiB | 13 Q