3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arrayA = array(); $arrayB = array(&$arrayA); $arrayA[] = &$arrayB; var_dump($arrayA,$arrayB); var_dump(serialize($arrayA)); var_dump(json_encode($arrayA));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/2ahf1
function name:  (null)
number of ops:  22
compiled vars:  !0 = $arrayA, !1 = $arrayB
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        INIT_ARRAY                                       ~3      !0
          2        ASSIGN                                                   !1, ~3
    5     3        FETCH_DIM_W                                      $5      !0
          4        ASSIGN_REF                                               $5, !1
    7     5        INIT_FCALL                                               'var_dump'
          6        SEND_VAR                                                 !0
          7        SEND_VAR                                                 !1
          8        DO_ICALL                                                 
    9     9        INIT_FCALL                                               'var_dump'
         10        INIT_FCALL                                               'serialize'
         11        SEND_VAR                                                 !0
         12        DO_ICALL                                         $8      
         13        SEND_VAR                                                 $8
         14        DO_ICALL                                                 
   10    15        INIT_FCALL                                               'var_dump'
         16        INIT_FCALL                                               'json_encode'
         17        SEND_VAR                                                 !0
         18        DO_ICALL                                         $10     
         19        SEND_VAR                                                 $10
         20        DO_ICALL                                                 
         21      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
172.53 ms | 1395 KiB | 19 Q