3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A implements Serializable { public function serialize($a) {} public function unserialize($a) {} } $r = new ReflectionClass("A"); foreach($r->getMethods() as $method) { echo $method->getDeclaringClass()->getName().'::'.$method->getName()."\n"; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 8, Position 2 = 20
Branch analysis from position: 8
2 jumps found. (Code = 78) Position 1 = 9, Position 2 = 20
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 8
Branch analysis from position: 8
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
filename:       /in/XOrmt
function name:  (null)
number of ops:  22
compiled vars:  !0 = $r, !1 = $method
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   DECLARE_CLASS                                            'a'
    6     1        NEW                                              $2      'ReflectionClass'
          2        SEND_VAL_EX                                              'A'
          3        DO_FCALL                                      0          
          4        ASSIGN                                                   !0, $2
    7     5        INIT_METHOD_CALL                                         !0, 'getMethods'
          6        DO_FCALL                                      0  $5      
          7      > FE_RESET_R                                       $6      $5, ->20
          8    > > FE_FETCH_R                                               $6, !1, ->20
    8     9    >   INIT_METHOD_CALL                                         !1, 'getDeclaringClass'
         10        DO_FCALL                                      0  $7      
         11        INIT_METHOD_CALL                                         $7, 'getName'
         12        DO_FCALL                                      0  $8      
         13        CONCAT                                           ~9      $8, '%3A%3A'
         14        INIT_METHOD_CALL                                         !1, 'getName'
         15        DO_FCALL                                      0  $10     
         16        CONCAT                                           ~11     ~9, $10
         17        CONCAT                                           ~12     ~11, '%0A'
         18        ECHO                                                     ~12
    7    19      > JMP                                                      ->8
         20    >   FE_FREE                                                  $6
    9    21      > RETURN                                                   1

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

End of function serialize

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

End of function unserialize

End of class A.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.4 ms | 1386 KiB | 13 Q