3v4l.org

run code in 300+ PHP versions simultaneously
<?php /* $a = '0xf'; $b = '15'; $c = 15; var_dump('Vars', $a, $b, $c); var_dump('EQ', $a == $b, $a == $c, $b == $c); */ test('pie', function($a){return $a;}); function test($label, $lambda){ static $a = ['0xf', '15', 15]; echo $label; foreach($a AS $k=>$v) { $r = $labda($v); var_export($r); } echo "\n"; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Q4KA1
function name:  (null)
number of ops:  6
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   INIT_FCALL_BY_NAME                                       'test'
          1        SEND_VAL_EX                                              'pie'
          2        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FQ4KA1%3A12%240'
          3        SEND_VAL_EX                                              ~0
          4        DO_FCALL                                      0          
   23     5      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FQ4KA1%3A12%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Q4KA1
function name:  {closure}
number of ops:  3
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   RECV                                             !0      
          1      > RETURN                                                   !0
          2*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FQ4KA1%3A12%240

Function test:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 5, Position 2 = 15
Branch analysis from position: 5
2 jumps found. (Code = 78) Position 1 = 6, Position 2 = 15
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 5
Branch analysis from position: 5
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 15
filename:       /in/Q4KA1
function name:  test
number of ops:  18
compiled vars:  !0 = $label, !1 = $lambda, !2 = $a, !3 = $v, !4 = $k, !5 = $r, !6 = $labda
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   16     2        BIND_STATIC                                              !2
   17     3        ECHO                                                     !0
   18     4      > FE_RESET_R                                       $7      !2, ->15
          5    > > FE_FETCH_R                                       ~8      $7, !3, ->15
          6    >   ASSIGN                                                   !4, ~8
   19     7        INIT_DYNAMIC_CALL                                        !6
          8        SEND_VAR_EX                                              !3
          9        DO_FCALL                                      0  $10     
         10        ASSIGN                                                   !5, $10
   20    11        INIT_FCALL                                               'var_export'
         12        SEND_VAR                                                 !5
         13        DO_ICALL                                                 
   18    14      > JMP                                                      ->5
         15    >   FE_FREE                                                  $7
   22    16        ECHO                                                     '%0A'
   23    17      > RETURN                                                   null

End of function test

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.45 ms | 1396 KiB | 15 Q