3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Nunber{ public $a; public $b; function Soma(){ return $this->a+$this->b; } } $n = new Nunber; $n->a = 5; $n->b = 6; $s = serialize($n); echo $n->Soma(); $n2 = unserialize($s); print_r($s);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/JOcL4
function name:  (null)
number of ops:  22
compiled vars:  !0 = $n, !1 = $s, !2 = $n2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   NEW                                              $3      'Nunber'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $3
   13     3        ASSIGN_OBJ                                               !0, 'a'
          4        OP_DATA                                                  5
   14     5        ASSIGN_OBJ                                               !0, 'b'
          6        OP_DATA                                                  6
   16     7        INIT_FCALL                                               'serialize'
          8        SEND_VAR                                                 !0
          9        DO_ICALL                                         $8      
         10        ASSIGN                                                   !1, $8
   18    11        INIT_METHOD_CALL                                         !0, 'Soma'
         12        DO_FCALL                                      0  $10     
         13        ECHO                                                     $10
   20    14        INIT_FCALL                                               'unserialize'
         15        SEND_VAR                                                 !1
         16        DO_ICALL                                         $11     
         17        ASSIGN                                                   !2, $11
   22    18        INIT_FCALL                                               'print_r'
         19        SEND_VAR                                                 !1
         20        DO_ICALL                                                 
         21      > RETURN                                                   1

Class Nunber:
Function soma:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/JOcL4
function name:  Soma
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   FETCH_OBJ_R                                      ~0      'a'
          1        FETCH_OBJ_R                                      ~1      'b'
          2        ADD                                              ~2      ~0, ~1
          3      > RETURN                                                   ~2
    8     4*     > RETURN                                                   null

End of function soma

End of class Nunber.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.54 ms | 1387 KiB | 19 Q