3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class void { public function bind() { } public function closure() { $_v = $this; return function () use ($_v) { return $this->bind(); }; } }
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = -2
filename:       /in/Om6Il
function name:  (null)
number of ops:  2
compiled vars:  none
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   2     0  E >   NOP                                                      
  17     1      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FOm6Il0x7fcd050e70b5:
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = -2
filename:       /in/Om6Il
function name:  {closure}
number of ops:  6
compiled vars:  !0 = $_v
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  13     0  E >   FETCH_R                      static              $1      '_v'
         1        ASSIGN                                                   !0, $1
  14     2        INIT_METHOD_CALL                                         'bind'
         3        DO_FCALL                                      0  $3      
         4      > RETURN                                                   $3
  15     5*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FOm6Il0x7fcd050e70b5

Class void:
Function bind:
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = -2
filename:       /in/Om6Il
function name:  bind
number of ops:  1
compiled vars:  none
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   7     0  E > > RETURN                                                   null

End of function bind

Function closure:
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = -2
filename:       /in/Om6Il
function name:  closure
number of ops:  4
compiled vars:  !0 = $_v, !1 = $this
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  11     0  E >   ASSIGN                                                   !0, !1
  13     1        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FOm6Il0x7fcd050e70b5'
  15     2      > RETURN                                                   ~3
  16     3*     > RETURN                                                   null

End of function closure

End of class void.

Generated using Vulcan Logic Dumper, using php 7.2.0