3v4l.org

run code in 300+ PHP versions simultaneously
<?php class dupa { public $a = 'j'; public static $NICE = 'STATIC_VALUE'; public function __construct($param) { $this->a = $param; echo '+_construct'.$this->a.self::$NICE; } public function __call($a, $b) { echo 'Wywolano metodÄ™ '.$a.' z parametrem'; if(is_array($b)){ foreach($b as $name=>$val) { echo 'nazwa: '.$name.'wartosc: '.$val; } } else { echo $b; } } 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') ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Uiss7
function name:  (null)
number of ops:  19
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   28     0  E >   NEW                                              $2      'dupa'
          1        SEND_VAL_EX                                              'blabla'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $2
   29     4        FETCH_OBJ_R                                      ~5      !0, 'a'
          5        ECHO                                                     ~5
   30     6        NEW                                              $6      'dupa'
          7        SEND_VAL_EX                                              ''
          8        DO_FCALL                                      0          
          9        ASSIGN                                                   !1, $6
   31    10        FETCH_OBJ_R                                      ~9      !1, 'a'
         11        ECHO                                                     ~9
   32    12        INIT_METHOD_CALL                                         !1, 'setA'
         13        SEND_VAL_EX                                              'bb'
         14        DO_FCALL                                      0          
   33    15        INIT_METHOD_CALL                                         !1, 'setb'
         16        SEND_VAL_EX                                              'bb'
         17        DO_FCALL                                      0          
   34    18      > RETURN                                                   1

Class dupa:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Uiss7
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 __call:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 7, Position 2 = 17
Branch analysis from position: 7
2 jumps found. (Code = 77) Position 1 = 8, Position 2 = 15
Branch analysis from position: 8
2 jumps found. (Code = 78) Position 1 = 9, Position 2 = 15
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 8
Branch analysis from position: 8
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 18
Branch analysis from position: 18
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 15
Branch analysis from position: 17
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Uiss7
function name:  __call
number of ops:  19
compiled vars:  !0 = $a, !1 = $b, !2 = $val, !3 = $name
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   12     2        CONCAT                                           ~4      'Wywolano+metod%C4%99+', !0
          3        CONCAT                                           ~5      ~4, '+z+parametrem'
          4        ECHO                                                     ~5
   13     5        TYPE_CHECK                                  128          !1
          6      > JMPZ                                                     ~6, ->17
   14     7    > > FE_RESET_R                                       $7      !1, ->15
          8    > > FE_FETCH_R                                       ~8      $7, !2, ->15
          9    >   ASSIGN                                                   !3, ~8
   16    10        CONCAT                                           ~10     'nazwa%3A+', !3
         11        CONCAT                                           ~11     ~10, 'wartosc%3A+'
         12        CONCAT                                           ~12     ~11, !2
         13        ECHO                                                     ~12
   14    14      > JMP                                                      ->8
         15    >   FE_FREE                                                  $7
         16      > JMP                                                      ->18
   19    17    >   ECHO                                                     !1
   21    18    > > 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/Uiss7
function name:  setA
number of ops:  4
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   23     0  E >   RECV                                             !0      
   24     1        ASSIGN_OBJ                                               'a'
          2        OP_DATA                                                  !0
   25     3      > RETURN                                                   null

End of function seta

End of class dupa.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
166.49 ms | 1399 KiB | 13 Q