3v4l.org

run code in 300+ PHP versions simultaneously
<?php $d = new DateTime('2015-01-01'); $a = array(new DateTime('2015-01-01'), new DateTime('2015-02-01')); echo in_array($d, $a) ? 'yes' : 'no';
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 18, Position 2 = 20
Branch analysis from position: 18
1 jumps found. (Code = 42) Position 1 = 21
Branch analysis from position: 21
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ci70M
function name:  (null)
number of ops:  23
compiled vars:  !0 = $d, !1 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $2      'DateTime'
          1        SEND_VAL_EX                                              '2015-01-01'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $2
    4     4        NEW                                              $5      'DateTime'
          5        SEND_VAL_EX                                              '2015-01-01'
          6        DO_FCALL                                      0          
          7        INIT_ARRAY                                       ~7      $5
          8        NEW                                              $8      'DateTime'
          9        SEND_VAL_EX                                              '2015-02-01'
         10        DO_FCALL                                      0          
         11        ADD_ARRAY_ELEMENT                                ~7      $8
         12        ASSIGN                                                   !1, ~7
    6    13        INIT_FCALL                                               'in_array'
         14        SEND_VAR                                                 !0
         15        SEND_VAR                                                 !1
         16        DO_ICALL                                         $11     
         17      > JMPZ                                                     $11, ->20
         18    >   QM_ASSIGN                                        ~12     'yes'
         19      > JMP                                                      ->21
         20    >   QM_ASSIGN                                        ~12     'no'
         21    >   ECHO                                                     ~12
         22      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
185.45 ms | 1395 KiB | 15 Q