3v4l.org

run code in 300+ PHP versions simultaneously
<?php $myclass = new class { public function foo() { echo "blah"; } }; $myvar = clone $myclass; var_dump($myvar instanceof $myclass);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/B7UO7
function name:  (null)
number of ops:  12
compiled vars:  !0 = $myclass, !1 = $myvar
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   DECLARE_ANON_CLASS                               <true>  
          1        NEW                                              $3      $2
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $3
   11     4        CLONE                                            ~6      !0
          5        ASSIGN                                                   !1, ~6
   13     6        INIT_FCALL                                               'var_dump'
          7        FETCH_CLASS                                   0  $8      !0
          8        INSTANCEOF                                       ~9      !1, $8
          9        SEND_VAL                                                 ~9
         10        DO_ICALL                                                 
         11      > RETURN                                                   1

Class class@anonymous:
Function foo:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/B7UO7
function name:  foo
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   ECHO                                                     'blah'
    8     1      > RETURN                                                   null

End of function foo

End of class class@anonymous.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
164.65 ms | 1394 KiB | 15 Q