3v4l.org

run code in 300+ PHP versions simultaneously
<?php class UserData{ public $user; public $userid; public function __construct($username, $userid){ $this->user = $username; $this->userid = $userid; echo "Username is {$this->user} and user id is{$this->userid}"; } public function __destruct(){ unset($this->user); unset($this->userid); } } $user = "mamun"; $id = "25"; $ur = new UserData($user, $id); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lXbTh
function name:  (null)
number of ops:  8
compiled vars:  !0 = $user, !1 = $id, !2 = $ur
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   18     0  E >   ASSIGN                                                   !0, 'mamun'
   19     1        ASSIGN                                                   !1, '25'
   20     2        NEW                                              $5      'UserData'
          3        SEND_VAR_EX                                              !0
          4        SEND_VAR_EX                                              !1
          5        DO_FCALL                                      0          
          6        ASSIGN                                                   !2, $5
   27     7      > RETURN                                                   1

Class UserData:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lXbTh
function name:  __construct
number of ops:  14
compiled vars:  !0 = $username, !1 = $userid
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    7     2        ASSIGN_OBJ                                               'user'
          3        OP_DATA                                                  !0
    8     4        ASSIGN_OBJ                                               'userid'
          5        OP_DATA                                                  !1
    9     6        ROPE_INIT                                     4  ~7      'Username+is+'
          7        FETCH_OBJ_R                                      ~4      'user'
          8        ROPE_ADD                                      1  ~7      ~7, ~4
          9        ROPE_ADD                                      2  ~7      ~7, '+and+user+id+is'
         10        FETCH_OBJ_R                                      ~5      'userid'
         11        ROPE_END                                      3  ~6      ~7, ~5
         12        ECHO                                                     ~6
   10    13      > RETURN                                                   null

End of function __construct

Function __destruct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/lXbTh
function name:  __destruct
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   UNSET_OBJ                                                'user'
   13     1        UNSET_OBJ                                                'userid'
   14     2      > RETURN                                                   null

End of function __destruct

End of class UserData.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.93 ms | 1395 KiB | 13 Q