3v4l.org

run code in 300+ PHP versions simultaneously
<?php final class dupa { public $a; public static $NICE = 'STATIC_VALUE'; public function __construct($param) { $this->a = $param; echo '+_construct'.$this->a.self::$NICE; } public static function statek(){ echo "\nWywolano metode statyczna"; } public function __call($a, $b) { echo "\n".'Wywolano metodÄ™ \''.$a.'\' z parametrami:'."\n"; foreach($b as $i=>$val) { echo 'indeks: '.$i.'wartosc: '.$val."\n"; } } public function setA($a) { $this->a = $a; } }; $a = new dupa('blabla'); echo $a->a; $b = new dupa(''); echo $b->a; $b->setA('bb'); $b->setb('bb',8,true); echo dupa::$NICE; dupa::statek(); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/V3H5Q
function name:  (null)
number of ops:  25
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   29     0  E >   NEW                                              $2      'dupa'
          1        SEND_VAL_EX                                              'blabla'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $2
   30     4        FETCH_OBJ_R                                      ~5      !0, 'a'
          5        ECHO                                                     ~5
   31     6        NEW                                              $6      'dupa'
          7        SEND_VAL_EX                                              ''
          8        DO_FCALL                                      0          
          9        ASSIGN                                                   !1, $6
   32    10        FETCH_OBJ_R                                      ~9      !1, 'a'
         11        ECHO                                                     ~9
   33    12        INIT_METHOD_CALL                                         !1, 'setA'
         13        SEND_VAL_EX                                              'bb'
         14        DO_FCALL                                      0          
   34    15        INIT_METHOD_CALL                                         !1, 'setb'
         16        SEND_VAL_EX                                              'bb'
         17        SEND_VAL_EX                                              8
         18        SEND_VAL_EX                                              <true>
         19        DO_FCALL                                      0          
   35    20        FETCH_STATIC_PROP_R          unknown             ~12     'NICE'
         21        ECHO                                                     ~12
   36    22        INIT_STATIC_METHOD_CALL                                  'dupa', 'statek'
         23        DO_FCALL                                      0          
   38    24      > RETURN                                                   1

Class dupa:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/V3H5Q
function name:  __construct
number of ops:  9
compiled vars:  !0 = $param
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
    8     1        ASSIGN_OBJ                                               'a'
          2        OP_DATA                                                  !0
    9     3        FETCH_OBJ_R                                      ~2      'a'
          4        CONCAT                                           ~3      '%2B_construct', ~2
          5        FETCH_STATIC_PROP_R          unknown             ~4      'NICE'
          6        CONCAT                                           ~5      ~3, ~4
          7        ECHO                                                     ~5
   10     8      > RETURN                                                   null

End of function __construct

Function statek:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/V3H5Q
function name:  statek
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   ECHO                                                     '%0AWywolano+metode+statyczna'
   15     1      > RETURN                                                   null

End of function statek

Function __call:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 7, Position 2 = 15
Branch analysis from position: 7
2 jumps found. (Code = 78) Position 1 = 8, Position 2 = 15
Branch analysis from position: 8
1 jumps found. (Code = 42) Position 1 = 7
Branch analysis from position: 7
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 15
filename:       /in/V3H5Q
function name:  __call
number of ops:  17
compiled vars:  !0 = $a, !1 = $b, !2 = $val, !3 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   17     2        CONCAT                                           ~4      '%0AWywolano+metod%C4%99+%27', !0
          3        CONCAT                                           ~5      ~4, '%27+z+parametrami%3A'
          4        CONCAT                                           ~6      ~5, '%0A'
          5        ECHO                                                     ~6
   18     6      > FE_RESET_R                                       $7      !1, ->15
          7    > > FE_FETCH_R                                       ~8      $7, !2, ->15
          8    >   ASSIGN                                                   !3, ~8
   20     9        CONCAT                                           ~10     'indeks%3A+', !3
         10        CONCAT                                           ~11     ~10, 'wartosc%3A+'
         11        CONCAT                                           ~12     ~11, !2
         12        CONCAT                                           ~13     ~12, '%0A'
         13        ECHO                                                     ~13
   18    14      > JMP                                                      ->7
         15    >   FE_FREE                                                  $7
   22    16      > RETURN                                                   null

End of function __call

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

End of function seta

End of class dupa.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.59 ms | 1390 KiB | 13 Q