3v4l.org

run code in 300+ PHP versions simultaneously
<?php interface Foo { public function thing($a = 'asdf'); } class MyFoo implements Foo { public function thing($a) { var_dump($a); } } $foo = new MyFoo(); $foo->thing();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/kJVBb
function name:  (null)
number of ops:  7
compiled vars:  !0 = $foo
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   DECLARE_CLASS                                            'myfoo'
   10     1        NEW                                              $1      'MyFoo'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $1
   11     4        INIT_METHOD_CALL                                         !0, 'thing'
          5        DO_FCALL                                      0          
          6      > RETURN                                                   1

Class Foo:
Function thing:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/kJVBb
function name:  thing
number of ops:  2
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV_INIT                                        !0      'asdf'
          1      > RETURN                                                   null

End of function thing

End of class Foo.

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

End of function thing

End of class MyFoo.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
146.94 ms | 1395 KiB | 15 Q