3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Token implements \Serializable { public function serialize() {} public function unserialize($str) { $r = unserialize($str); unserialize($r[2]); } } $token = file_get_contents('string2.txt'); $obj = unserialize($token);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Mgsvi
function name:  (null)
number of ops:  10
compiled vars:  !0 = $token, !1 = $obj
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   DECLARE_CLASS                                            'token'
   15     1        INIT_FCALL                                               'file_get_contents'
          2        SEND_VAL                                                 'string2.txt'
          3        DO_ICALL                                         $2      
          4        ASSIGN                                                   !0, $2
   16     5        INIT_FCALL                                               'unserialize'
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                         $4      
          8        ASSIGN                                                   !1, $4
          9      > RETURN                                                   1

Class Token:
Function serialize:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Mgsvi
function name:  serialize
number of ops:  1
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E > > RETURN                                                   null

End of function serialize

Function unserialize:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Mgsvi
function name:  unserialize
number of ops:  10
compiled vars:  !0 = $str, !1 = $r
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
    9     1        INIT_FCALL                                               'unserialize'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $2      
          4        ASSIGN                                                   !1, $2
   10     5        INIT_FCALL                                               'unserialize'
          6        FETCH_DIM_R                                      ~4      !1, 2
          7        SEND_VAL                                                 ~4
          8        DO_ICALL                                                 
   11     9      > RETURN                                                   null

End of function unserialize

End of class Token.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
161.3 ms | 1395 KiB | 17 Q