3v4l.org

run code in 300+ PHP versions simultaneously
<?php function a (&$b) { return json_encode($b); } $x = new stdClass(); $x->blop = 'bla'; $x->bla = 3; $x->bar = array('baz' => 'apple'); $y = a($x); var_dump($y);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/3S3FV
function name:  (null)
number of ops:  17
compiled vars:  !0 = $x, !1 = $y
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   NEW                                              $2      'stdClass'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
    7     3        ASSIGN_OBJ                                               !0, 'blop'
          4        OP_DATA                                                  'bla'
    8     5        ASSIGN_OBJ                                               !0, 'bla'
          6        OP_DATA                                                  3
    9     7        ASSIGN_OBJ                                               !0, 'bar'
          8        OP_DATA                                                  <array>
   11     9        INIT_FCALL                                               'a'
         10        SEND_REF                                                 !0
         11        DO_FCALL                                      0  $8      
         12        ASSIGN                                                   !1, $8
   13    13        INIT_FCALL                                               'var_dump'
         14        SEND_VAR                                                 !1
         15        DO_ICALL                                                 
         16      > RETURN                                                   1

Function a:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/3S3FV
function name:  a
number of ops:  6
compiled vars:  !0 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   RECV                                             !0      
    3     1        INIT_FCALL                                               'json_encode'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $1      
          4      > RETURN                                                   $1
    4     5*     > RETURN                                                   null

End of function a

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
164.99 ms | 1398 KiB | 18 Q