3v4l.org

run code in 300+ PHP versions simultaneously
<?php $dt = new DateTimeImmutable(); echo $dt->format(DATE_ISO8601).PHP_EOL; $currenthour = $dt->format("H"); echo $currenthour.PHP_EOL; $dt2 = $dt->setTime($currenthour, 0, 0); echo $dt2->format(DATE_ISO8601).PHP_EOL;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/5Q8LW
function name:  (null)
number of ops:  26
compiled vars:  !0 = $dt, !1 = $currenthour, !2 = $dt2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $3      'DateTimeImmutable'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $3
    4     3        INIT_METHOD_CALL                                         !0, 'format'
          4        SEND_VAL_EX                                              'Y-m-d%5CTH%3Ai%3AsO'
          5        DO_FCALL                                      0  $6      
          6        CONCAT                                           ~7      $6, '%0A'
          7        ECHO                                                     ~7
    5     8        INIT_METHOD_CALL                                         !0, 'format'
          9        SEND_VAL_EX                                              'H'
         10        DO_FCALL                                      0  $8      
         11        ASSIGN                                                   !1, $8
    6    12        CONCAT                                           ~10     !1, '%0A'
         13        ECHO                                                     ~10
    7    14        INIT_METHOD_CALL                                         !0, 'setTime'
         15        SEND_VAR_EX                                              !1
         16        SEND_VAL_EX                                              0
         17        SEND_VAL_EX                                              0
         18        DO_FCALL                                      0  $11     
         19        ASSIGN                                                   !2, $11
    8    20        INIT_METHOD_CALL                                         !2, 'format'
         21        SEND_VAL_EX                                              'Y-m-d%5CTH%3Ai%3AsO'
         22        DO_FCALL                                      0  $13     
         23        CONCAT                                           ~14     $13, '%0A'
         24        ECHO                                                     ~14
    9    25      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
145.5 ms | 1085 KiB | 13 Q