3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = function(&$arg) { echo "ok"; }; $z = 1; class MyContext {} $a->call(new MyContext, $z);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/SPse9
function name:  (null)
number of ops:  10
compiled vars:  !0 = $a, !1 = $z
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FSPse9%3A3%240'
          1        ASSIGN                                                   !0, ~2
    4     2        ASSIGN                                                   !1, 1
    6     3        INIT_METHOD_CALL                                         !0, 'call'
          4        NEW                                              $5      'MyContext'
          5        DO_FCALL                                      0          
          6        SEND_VAR_NO_REF_EX                                       $5
          7        SEND_VAR_EX                                              !1
          8        DO_FCALL                                      0          
          9      > RETURN                                                   1

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

End of function %00%7Bclosure%7D%2Fin%2FSPse9%3A3%240

Class MyContext: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.54 ms | 1397 KiB | 13 Q