3v4l.org

run code in 300+ PHP versions simultaneously
<?php $my_obj1 = ["0" => "something"]; $my_obj1 = json_encode($my_obj1, JSON_FORCE_OBJECT); $my_obj2 = ["1" => "something else"]; $my_obj2 = json_encode($my_obj2); echo json_encode(json_decode($my_obj1));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/st15L
function name:  (null)
number of ops:  19
compiled vars:  !0 = $my_obj1, !1 = $my_obj2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        INIT_FCALL                                               'json_encode'
          2        SEND_VAR                                                 !0
          3        SEND_VAL                                                 16
          4        DO_ICALL                                         $3      
          5        ASSIGN                                                   !0, $3
    6     6        ASSIGN                                                   !1, <array>
    7     7        INIT_FCALL                                               'json_encode'
          8        SEND_VAR                                                 !1
          9        DO_ICALL                                         $6      
         10        ASSIGN                                                   !1, $6
    9    11        INIT_FCALL                                               'json_encode'
         12        INIT_FCALL                                               'json_decode'
         13        SEND_VAR                                                 !0
         14        DO_ICALL                                         $8      
         15        SEND_VAR                                                 $8
         16        DO_ICALL                                         $9      
         17        ECHO                                                     $9
         18      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
141.64 ms | 998 KiB | 15 Q