3v4l.org

run code in 300+ PHP versions simultaneously
<?php class a { static function test() {return "A";} } if(method_exists('a','test')) print call_user_func(array('a','test')); else print "Nothing"; ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 9
Branch analysis from position: 5
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 9
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/cSoIM
function name:  (null)
number of ops:  11
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   INIT_FCALL                                               'method_exists'
          1        SEND_VAL                                                 'a'
          2        SEND_VAL                                                 'test'
          3        DO_ICALL                                         $0      
          4      > JMPZ                                                     $0, ->9
    6     5    >   INIT_USER_CALL                                0          'call_user_func', <array>
          6        DO_FCALL                                      0  $1      
          7        ECHO                                                     $1
          8      > JMP                                                      ->10
    8     9    >   ECHO                                                     'Nothing'
    9    10    > > RETURN                                                   1

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

End of function test

End of class a.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.24 ms | 1386 KiB | 15 Q