3v4l.org

run code in 500+ PHP versions simultaneously
<?php class A { public $prop = [1,2,3]; } class B{ public $someProp; } $a = new A; $b = new B; $b->someProp = $a->prop; mb_convert_variables('UTF-8', 'CP1252', $b); $a = new A; print_r($a); # example 2 class C { public $prop = ['string', 'string2']; } $c = new C; mb_convert_variables('UTF-8', 'CP1252', $c); $c = new C; print_r($c);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/d8fth
function name:  (null)
number of ops:  35
compiled vars:  !0 = $a, !1 = $b, !2 = $c
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   10     0  E >   NEW                                                  $3      'A'
          1        DO_FCALL                                          0          
          2        ASSIGN                                                       !0, $3
   11     3        NEW                                                  $6      'B'
          4        DO_FCALL                                          0          
          5        ASSIGN                                                       !1, $6
   12     6        FETCH_OBJ_R                                          ~10     !0, 'prop'
          7        ASSIGN_OBJ                                                   !1, 'someProp'
          8        OP_DATA                                                      ~10
   13     9        INIT_FCALL                                                   'mb_convert_variables'
         10        SEND_VAL                                                     'UTF-8'
         11        SEND_VAL                                                     'CP1252'
         12        SEND_REF                                                     !1
         13        DO_ICALL                                                     
   15    14        NEW                                                  $12     'A'
         15        DO_FCALL                                          0          
         16        ASSIGN                                                       !0, $12
   16    17        INIT_FCALL                                                   'print_r'
         18        SEND_VAR                                                     !0
         19        DO_ICALL                                                     
   23    20        NEW                                                  $16     'C'
         21        DO_FCALL                                          0          
         22        ASSIGN                                                       !2, $16
   24    23        INIT_FCALL                                                   'mb_convert_variables'
         24        SEND_VAL                                                     'UTF-8'
         25        SEND_VAL                                                     'CP1252'
         26        SEND_REF                                                     !2
         27        DO_ICALL                                                     
   25    28        NEW                                                  $20     'C'
         29        DO_FCALL                                          0          
         30        ASSIGN                                                       !2, $20
   26    31        INIT_FCALL                                                   'print_r'
         32        SEND_VAR                                                     !2
         33        DO_ICALL                                                     
         34      > RETURN                                                       1

Class A: [no user functions]
Class B: [no user functions]
Class C: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
155.62 ms | 1625 KiB | 10 Q