3v4l.org

run code in 300+ PHP versions simultaneously
<?php var_dump( in_array(0, ['this', 'that', 1, 2]) ); var_dump( in_array(0, ['this', 'that']) ); var_dump( in_array(false, ['this', 'that']) ); var_dump( in_array(true, ['this', 'that']) ); var_dump( in_array(true, [true, false]) ); var_dump( in_array(false, [true, false]) ); var_dump( in_array(null, ['this', 'that', 1, 2]) );
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/NmgbE
function name:  (null)
number of ops:  41
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'var_dump'
    4     1        INIT_FCALL                                               'in_array'
          2        SEND_VAL                                                 0
          3        SEND_VAL                                                 <array>
          4        DO_ICALL                                         $0      
          5        SEND_VAR                                                 $0
          6        DO_ICALL                                                 
    6     7        INIT_FCALL                                               'var_dump'
    7     8        IN_ARRAY                                         ~2      0, <array>
          9        SEND_VAL                                                 ~2
         10        DO_ICALL                                                 
    9    11        INIT_FCALL                                               'var_dump'
   10    12        IN_ARRAY                                         ~4      <false>, <array>
         13        SEND_VAL                                                 ~4
         14        DO_ICALL                                                 
   13    15        INIT_FCALL                                               'var_dump'
   14    16        IN_ARRAY                                         ~6      <true>, <array>
         17        SEND_VAL                                                 ~6
         18        DO_ICALL                                                 
   16    19        INIT_FCALL                                               'var_dump'
   17    20        INIT_FCALL                                               'in_array'
         21        SEND_VAL                                                 <true>
         22        SEND_VAL                                                 <array>
         23        DO_ICALL                                         $8      
         24        SEND_VAR                                                 $8
         25        DO_ICALL                                                 
   19    26        INIT_FCALL                                               'var_dump'
   20    27        INIT_FCALL                                               'in_array'
         28        SEND_VAL                                                 <false>
         29        SEND_VAL                                                 <array>
         30        DO_ICALL                                         $10     
         31        SEND_VAR                                                 $10
         32        DO_ICALL                                                 
   23    33        INIT_FCALL                                               'var_dump'
   24    34        INIT_FCALL                                               'in_array'
         35        SEND_VAL                                                 null
         36        SEND_VAL                                                 <array>
         37        DO_ICALL                                         $12     
         38        SEND_VAR                                                 $12
         39        DO_ICALL                                                 
   25    40      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
159.27 ms | 1388 KiB | 17 Q