3v4l.org

run code in 300+ PHP versions simultaneously
<?php class testA { private $b = 123; public function __construct() { $a = 5; } } $className = "testA"; $object = unserialize( sprintf('C:%d:"%s":0:{}', strlen($className), $className) ); var_dump($object);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/vSi8q
function name:  (null)
number of ops:  15
compiled vars:  !0 = $className, !1 = $object
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   ASSIGN                                                   !0, 'testA'
   16     1        INIT_FCALL                                               'unserialize'
   17     2        INIT_FCALL                                               'sprintf'
          3        SEND_VAL                                                 'C%3A%25d%3A%22%25s%22%3A0%3A%7B%7D'
          4        STRLEN                                           ~3      !0
          5        SEND_VAL                                                 ~3
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                         $4      
          8        SEND_VAR                                                 $4
          9        DO_ICALL                                         $5      
   16    10        ASSIGN                                                   !1, $5
   21    11        INIT_FCALL                                               'var_dump'
         12        SEND_VAR                                                 !1
         13        DO_ICALL                                                 
         14      > RETURN                                                   1

Class testA:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/vSi8q
function name:  __construct
number of ops:  2
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   ASSIGN                                                   !0, 5
   10     1      > RETURN                                                   null

End of function __construct

End of class testA.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.45 ms | 1395 KiB | 19 Q