3v4l.org

run code in 300+ PHP versions simultaneously
<?php class View { public function __toString() { $clean_room = function($__file_name, array $__data) { extract($__data, EXTR_REFS); return 'wat'; }; return $clean_room('foo.php', array()); } } $view = new View(); $response = (string)$view; echo $response; var_dump(PHP_DEBUG);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dsYdt
function name:  (null)
number of ops:  11
compiled vars:  !0 = $view, !1 = $response
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   DECLARE_CLASS                                            'view'
   12     1        NEW                                              $2      'View'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $2
   13     4        CAST                                          6  ~5      !0
          5        ASSIGN                                                   !1, ~5
   14     6        ECHO                                                     !1
   16     7        INIT_FCALL                                               'var_dump'
          8        SEND_VAL                                                 0
          9        DO_ICALL                                                 
         10      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FdsYdt%3A4%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dsYdt
function name:  {closure}
number of ops:  8
compiled vars:  !0 = $__file_name, !1 = $__data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    5     2        INIT_FCALL                                               'extract'
          3        SEND_REF                                                 !1
          4        SEND_VAL                                                 256
          5        DO_ICALL                                                 
    6     6      > RETURN                                                   'wat'
    7     7*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FdsYdt%3A4%240

Class View:
Function __tostring:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dsYdt
function name:  __toString
number of ops:  10
compiled vars:  !0 = $clean_room
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FdsYdt%3A4%240'
          1        ASSIGN                                                   !0, ~1
    8     2        INIT_DYNAMIC_CALL                                        !0
          3        SEND_VAL_EX                                              'foo.php'
          4        SEND_VAL_EX                                              <array>
          5        DO_FCALL                                      0  $3      
          6        VERIFY_RETURN_TYPE                                       $3
          7      > RETURN                                                   $3
    9     8*       VERIFY_RETURN_TYPE                                       
          9*     > RETURN                                                   null

End of function __tostring

End of class View.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
180.01 ms | 1396 KiB | 17 Q