3v4l.org

run code in 500+ PHP versions simultaneously
<?php $array = [ 'mark@test.by.com'=> "Mark Mian lv", 'jhon@test.lv.com'=> "John jack lv", 'logon@test.en.com'=> "Bob Logon", 'Stela@test.es.com'=> "Stela Josh", 'json@test.es.com'=> "Json Josh", 'bobby@test.lv.com'=> "Bob Mark" ]; $needle = 'b'; var_export( array_filter( $array, fn($v, $k) => str_contains($v, $needle) || str_contains($k, $needle), ARRAY_FILTER_USE_BOTH ) );
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uimRU
function name:  (null)
number of ops:  13
compiled vars:  !0 = $array, !1 = $needle
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, <array>
   12     1        ASSIGN                                                       !1, 'b'
   14     2        INIT_FCALL                                                   'var_export'
   15     3        INIT_FCALL                                                   'array_filter'
   16     4        SEND_VAR                                                     !0
   17     5        DECLARE_LAMBDA_FUNCTION                              ~4      [0]
          6        BIND_LEXICAL                                                 ~4, !1
          7        SEND_VAL                                                     ~4
   18     8        SEND_VAL                                                     1
   15     9        DO_ICALL                                             $5      
   18    10        SEND_VAR                                                     $5
   14    11        DO_ICALL                                                     
   20    12      > RETURN                                                       1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 47) Position 1 = 5, Position 2 = 7
Branch analysis from position: 5
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/uimRU
function name:  {closure:/in/uimRU:17}
number of ops:  9
compiled vars:  !0 = $v, !1 = $k, !2 = $needle
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   17     0  E >   RECV                                                 !0      
          1        RECV                                                 !1      
          2        BIND_STATIC                                                  !2
          3        FRAMELESS_ICALL_2                str_contains        ~3      !0, !2
          4      > JMPNZ_EX                                             ~3      ~3, ->7
          5    >   FRAMELESS_ICALL_2                str_contains        ~4      !1, !2
          6        BOOL                                                 ~3      ~4
          7    > > RETURN                                                       ~3
          8*     > RETURN                                                       null

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
126.64 ms | 478 KiB | 9 Q