3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { final private function __clone() { raise_error(" "); } } $x = new A; var_dump($x); //var_dump(clone $x); //var_dump(clone new A; var_dump(clone new Exception);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/udLSs
function name:  (null)
number of ops:  13
compiled vars:  !0 = $x
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   NEW                                              $1      'A'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   12     3        INIT_FCALL                                               'var_dump'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                                 
   15     6        INIT_FCALL                                               'var_dump'
          7        NEW                                              $5      'Exception'
          8        DO_FCALL                                      0          
          9        CLONE                                            ~7      $5
         10        SEND_VAL                                                 ~7
         11        DO_ICALL                                                 
         12      > RETURN                                                   1

Class A:
Function __clone:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/udLSs
function name:  __clone
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   INIT_FCALL_BY_NAME                                       'raise_error'
          1        SEND_VAL_EX                                              '++'
          2        DO_FCALL                                      0          
    7     3      > RETURN                                                   null

End of function __clone

End of class A.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
170.13 ms | 1395 KiB | 15 Q