3v4l.org

run code in 300+ PHP versions simultaneously
<?php $tomorrow = new DateTimeImmutable('tomorrow'); // Will be midnight in the am $dayAfter = $tomorrow->add(new DateInterval('P1D')); // Will also be midnight $timestamp = time(); $isTomorrow = ($timestamp > $tomorrow->getTimestamp() && $dayAfter->getTimestamp() > $timestamp); var_dump($isTomorrow); $timestamp = $timestamp + (60 * 60 * 24); $isTomorrow = ($timestamp > $tomorrow->getTimestamp() && $dayAfter->getTimestamp() > $timestamp); var_dump($isTomorrow); $timestamp = $timestamp + (60 * 60 * 24); $isTomorrow = ($timestamp > $tomorrow->getTimestamp() && $dayAfter->getTimestamp() > $timestamp); var_dump($isTomorrow);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 18, Position 2 = 22
Branch analysis from position: 18
2 jumps found. (Code = 46) Position 1 = 32, Position 2 = 36
Branch analysis from position: 32
2 jumps found. (Code = 46) Position 1 = 46, Position 2 = 50
Branch analysis from position: 46
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 50
Branch analysis from position: 36
Branch analysis from position: 22
filename:       /in/TpeAi
function name:  (null)
number of ops:  55
compiled vars:  !0 = $tomorrow, !1 = $dayAfter, !2 = $timestamp, !3 = $isTomorrow
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $4      'DateTimeImmutable'
          1        SEND_VAL_EX                                              'tomorrow'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $4
    4     4        INIT_METHOD_CALL                                         !0, 'add'
          5        NEW                                              $7      'DateInterval'
          6        SEND_VAL_EX                                              'P1D'
          7        DO_FCALL                                      0          
          8        SEND_VAR_NO_REF_EX                                       $7
          9        DO_FCALL                                      0  $9      
         10        ASSIGN                                                   !1, $9
    7    11        INIT_FCALL                                               'time'
         12        DO_ICALL                                         $11     
         13        ASSIGN                                                   !2, $11
    8    14        INIT_METHOD_CALL                                         !0, 'getTimestamp'
         15        DO_FCALL                                      0  $13     
         16        IS_SMALLER                                       ~14     $13, !2
         17      > JMPZ_EX                                          ~14     ~14, ->22
         18    >   INIT_METHOD_CALL                                         !1, 'getTimestamp'
         19        DO_FCALL                                      0  $15     
         20        IS_SMALLER                                       ~16     !2, $15
         21        BOOL                                             ~14     ~16
         22    >   ASSIGN                                                   !3, ~14
    9    23        INIT_FCALL                                               'var_dump'
         24        SEND_VAR                                                 !3
         25        DO_ICALL                                                 
   11    26        ADD                                              ~19     !2, 86400
         27        ASSIGN                                                   !2, ~19
   12    28        INIT_METHOD_CALL                                         !0, 'getTimestamp'
         29        DO_FCALL                                      0  $21     
         30        IS_SMALLER                                       ~22     $21, !2
         31      > JMPZ_EX                                          ~22     ~22, ->36
         32    >   INIT_METHOD_CALL                                         !1, 'getTimestamp'
         33        DO_FCALL                                      0  $23     
         34        IS_SMALLER                                       ~24     !2, $23
         35        BOOL                                             ~22     ~24
         36    >   ASSIGN                                                   !3, ~22
   13    37        INIT_FCALL                                               'var_dump'
         38        SEND_VAR                                                 !3
         39        DO_ICALL                                                 
   15    40        ADD                                              ~27     !2, 86400
         41        ASSIGN                                                   !2, ~27
   16    42        INIT_METHOD_CALL                                         !0, 'getTimestamp'
         43        DO_FCALL                                      0  $29     
         44        IS_SMALLER                                       ~30     $29, !2
         45      > JMPZ_EX                                          ~30     ~30, ->50
         46    >   INIT_METHOD_CALL                                         !1, 'getTimestamp'
         47        DO_FCALL                                      0  $31     
         48        IS_SMALLER                                       ~32     !2, $31
         49        BOOL                                             ~30     ~32
         50    >   ASSIGN                                                   !3, ~30
   17    51        INIT_FCALL                                               'var_dump'
         52        SEND_VAR                                                 !3
         53        DO_ICALL                                                 
         54      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
160.29 ms | 1400 KiB | 17 Q