3v4l.org

run code in 300+ PHP versions simultaneously
<?php $event = new DateTime('second Wednesday of April'); if(time() > $event->getTimestamp()){ $event->modify('+1 year'); } echo 'April ' . $event ->format('d') . '-' . $event->modify('+4 days')->format('d') . ', ' . $event->format('Y');
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 13
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 13
filename:       /in/Yd1Vt
function name:  (null)
number of ops:  32
compiled vars:  !0 = $event
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $1      'DateTime'
          1        SEND_VAL_EX                                              'second+Wednesday+of+April'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $1
    4     4        INIT_FCALL                                               'time'
          5        DO_ICALL                                         $4      
          6        INIT_METHOD_CALL                                         !0, 'getTimestamp'
          7        DO_FCALL                                      0  $5      
          8        IS_SMALLER                                               $5, $4
          9      > JMPZ                                                     ~6, ->13
    5    10    >   INIT_METHOD_CALL                                         !0, 'modify'
         11        SEND_VAL_EX                                              '%2B1+year'
         12        DO_FCALL                                      0          
    8    13    >   INIT_METHOD_CALL                                         !0, 'format'
         14        SEND_VAL_EX                                              'd'
         15        DO_FCALL                                      0  $8      
         16        CONCAT                                           ~9      'April+', $8
         17        CONCAT                                           ~10     ~9, '-'
         18        INIT_METHOD_CALL                                         !0, 'modify'
         19        SEND_VAL_EX                                              '%2B4+days'
         20        DO_FCALL                                      0  $11     
         21        INIT_METHOD_CALL                                         $11, 'format'
         22        SEND_VAL_EX                                              'd'
         23        DO_FCALL                                      0  $12     
         24        CONCAT                                           ~13     ~10, $12
         25        CONCAT                                           ~14     ~13, '%2C+'
         26        INIT_METHOD_CALL                                         !0, 'format'
         27        SEND_VAL_EX                                              'Y'
         28        DO_FCALL                                      0  $15     
         29        CONCAT                                           ~16     ~14, $15
         30        ECHO                                                     ~16
         31      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.58 ms | 1396 KiB | 15 Q