3v4l.org

run code in 300+ PHP versions simultaneously
<?php class test { function a() { echo 'test::a'; } } $callable = array(new test(), 'a'); if (is_callable($callable)) { echo 'is callable!'; } else { echo 'not callable'; } $callable();
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 9, Position 2 = 11
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 11
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lVVsC
function name:  (null)
number of ops:  15
compiled vars:  !0 = $callable
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   NEW                                              $1      'test'
          1        DO_FCALL                                      0          
          2        INIT_ARRAY                                       ~3      $1
          3        ADD_ARRAY_ELEMENT                                ~3      'a'
          4        ASSIGN                                                   !0, ~3
    8     5        INIT_FCALL                                               'is_callable'
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                         $5      
          8      > JMPZ                                                     $5, ->11
          9    >   ECHO                                                     'is+callable%21'
         10      > JMP                                                      ->12
         11    >   ECHO                                                     'not+callable'
   10    12    >   INIT_DYNAMIC_CALL                                        !0
         13        DO_FCALL                                      0          
         14      > RETURN                                                   1

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

End of function a

End of class test.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
142 ms | 1395 KiB | 15 Q