3v4l.org

run code in 300+ PHP versions simultaneously
<?php $now = new DateTime(null, new DateTimeZone('Europe/Berlin')); $soon = $now->add(new DateInterval('P1D')); $diff = $soon->diff($now); echo $diff->format('%R%a');;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/rbABr
function name:  (null)
number of ops:  24
compiled vars:  !0 = $now, !1 = $soon, !2 = $diff
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   NEW                                              $3      'DateTime'
          1        SEND_VAL_EX                                              null
          2        NEW                                              $4      'DateTimeZone'
          3        SEND_VAL_EX                                              'Europe%2FBerlin'
          4        DO_FCALL                                      0          
          5        SEND_VAR_NO_REF_EX                                       $4
          6        DO_FCALL                                      0          
          7        ASSIGN                                                   !0, $3
    3     8        INIT_METHOD_CALL                                         !0, 'add'
          9        NEW                                              $8      'DateInterval'
         10        SEND_VAL_EX                                              'P1D'
         11        DO_FCALL                                      0          
         12        SEND_VAR_NO_REF_EX                                       $8
         13        DO_FCALL                                      0  $10     
         14        ASSIGN                                                   !1, $10
    4    15        INIT_METHOD_CALL                                         !1, 'diff'
         16        SEND_VAR_EX                                              !0
         17        DO_FCALL                                      0  $12     
         18        ASSIGN                                                   !2, $12
    5    19        INIT_METHOD_CALL                                         !2, 'format'
         20        SEND_VAL_EX                                              '%25R%25a'
         21        DO_FCALL                                      0  $14     
         22        ECHO                                                     $14
         23      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
147.63 ms | 1393 KiB | 13 Q