3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array(1,2,3,4,5); function arrayFlip($a) { $b = array_flip($a); var_dump(isset($a[1])); } function inArray($a) { var_dump(in_array(1,$a)); } inArray($a);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hHeOt
function name:  (null)
number of ops:  5
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
   13     1        INIT_FCALL                                               'inarray'
          2        SEND_VAR                                                 !0
          3        DO_FCALL                                      0          
          4      > RETURN                                                   1

Function arrayflip:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hHeOt
function name:  arrayFlip
number of ops:  10
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        INIT_FCALL                                               'array_flip'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $2      
          4        ASSIGN                                                   !1, $2
    5     5        INIT_FCALL                                               'var_dump'
          6        ISSET_ISEMPTY_DIM_OBJ                         0  ~4      !0, 1
          7        SEND_VAL                                                 ~4
          8        DO_ICALL                                                 
    7     9      > RETURN                                                   null

End of function arrayflip

Function inarray:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hHeOt
function name:  inArray
number of ops:  9
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   RECV                                             !0      
   10     1        INIT_FCALL                                               'var_dump'
          2        INIT_FCALL                                               'in_array'
          3        SEND_VAL                                                 1
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $1      
          6        SEND_VAR                                                 $1
          7        DO_ICALL                                                 
   11     8      > RETURN                                                   null

End of function inarray

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.34 ms | 1399 KiB | 20 Q