3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Herman { private $milk; public function setMilk($flag) { $this->milk = $flag; } } $hermit = new Herman(); $hermit->setMilk(true); $serialized = serialize($hermit); echo "Serialized: ${serialized}";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Fn3nk
function name:  (null)
number of ops:  14
compiled vars:  !0 = $hermit, !1 = $serialized
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   NEW                                              $2      'Herman'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
   13     3        INIT_METHOD_CALL                                         !0, 'setMilk'
          4        SEND_VAL_EX                                              <true>
          5        DO_FCALL                                      0          
   15     6        INIT_FCALL                                               'serialize'
          7        SEND_VAR                                                 !0
          8        DO_ICALL                                         $6      
          9        ASSIGN                                                   !1, $6
   17    10        NOP                                                      
         11        FAST_CONCAT                                      ~8      'Serialized%3A+', !1
         12        ECHO                                                     ~8
         13      > RETURN                                                   1

Class Herman:
Function setmilk:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Fn3nk
function name:  setMilk
number of ops:  4
compiled vars:  !0 = $flag
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   RECV                                             !0      
    8     1        ASSIGN_OBJ                                               'milk'
          2        OP_DATA                                                  !0
    9     3      > RETURN                                                   null

End of function setmilk

End of class Herman.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
142.54 ms | 1395 KiB | 15 Q