3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Test { public $test; public $test2; public function serialize() { return serialize($this); } } $o = new Test(); $o->test = "aaaa"; $o->test2 = "bbbbb"; echo $o->serialize();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m2q13
function name:  (null)
number of ops:  11
compiled vars:  !0 = $o
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   NEW                                              $1      'Test'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   14     3        ASSIGN_OBJ                                               !0, 'test'
          4        OP_DATA                                                  'aaaa'
   15     5        ASSIGN_OBJ                                               !0, 'test2'
          6        OP_DATA                                                  'bbbbb'
   17     7        INIT_METHOD_CALL                                         !0, 'serialize'
          8        DO_FCALL                                      0  $6      
          9        ECHO                                                     $6
         10      > RETURN                                                   1

Class Test:
Function serialize:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m2q13
function name:  serialize
number of ops:  6
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   INIT_FCALL                                               'serialize'
          1        FETCH_THIS                                       ~0      
          2        SEND_VAL                                                 ~0
          3        DO_ICALL                                         $1      
          4      > RETURN                                                   $1
    9     5*     > RETURN                                                   null

End of function serialize

End of class Test.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.82 ms | 1395 KiB | 15 Q