3v4l.org

run code in 300+ PHP versions simultaneously
<?php $file = <<<XML <?xml version="1.0"?> <?xml-stylesheet href="catalog.xsl" type="text/xsl"?> <!DOCTYPE catalog SYSTEM "catalog.dtd"> <catalog> <product description="Cardigan Sweater" id="123" value="" product_image="cardigan.jpg"> <catalog_item gender="Men's"> <size description="Medium"> <color_swatch image="red_cardigan.jpg" id="color" value="Red"/> <color_swatch image="burgundy_cardigan.jpg" id="color" value="burgundy"/> </size> <size description="Large"> <color_swatch image="red_cardigan.jpg" id="color" value="Red"/> <color_swatch image="burgundy_cardigan.jpg" id="color" value="burgundy"/> </size> </catalog_item> </product> </catalog> XML; $xml = simplexml_load_string($file); foreach($xml as $product) { var_dump($product); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 6, Position 2 = 11
Branch analysis from position: 6
2 jumps found. (Code = 78) Position 1 = 7, Position 2 = 11
Branch analysis from position: 7
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
Branch analysis from position: 11
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 11
filename:       /in/jlLkh
function name:  (null)
number of ops:  13
compiled vars:  !0 = $file, !1 = $xml, !2 = $product
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%3C%3Fxml+version%3D%221.0%22%3F%3E%0A%3C%3Fxml-stylesheet+href%3D%22catalog.xsl%22+type%3D%22text%2Fxsl%22%3F%3E%0A%3C%21DOCTYPE+catalog+SYSTEM+%22catalog.dtd%22%3E%0A%3Ccatalog%3E%0A+++%3Cproduct+description%3D%22Cardigan+Sweater%22+id%3D%22123%22+value%3D%22%22+product_image%3D%22cardigan.jpg%22%3E%0A++++++%3Ccatalog_item+gender%3D%22Men%27s%22%3E%0A+++++++++%3Csize+description%3D%22Medium%22%3E%0A++++++++++++%3Ccolor_swatch+image%3D%22red_cardigan.jpg%22+id%3D%22color%22+value%3D%22Red%22%2F%3E%0A+++++++++++++%3Ccolor_swatch+image%3D%22burgundy_cardigan.jpg%22+id%3D%22color%22+value%3D%22burgundy%22%2F%3E%0A+++++++++%3C%2Fsize%3E%0A+++++++++%3Csize+description%3D%22Large%22%3E%0A+++++++++++%3Ccolor_swatch+image%3D%22red_cardigan.jpg%22+id%3D%22color%22+value%3D%22Red%22%2F%3E%0A++++++++++++%3Ccolor_swatch+image%3D%22burgundy_cardigan.jpg%22+id%3D%22color%22+value%3D%22burgundy%22%2F%3E%0A+++++++++%3C%2Fsize%3E%0A++++++%3C%2Fcatalog_item%3E%0A+++%3C%2Fproduct%3E%0A%3C%2Fcatalog%3E'
   23     1        INIT_FCALL                                               'simplexml_load_string'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $4      
          4        ASSIGN                                                   !1, $4
   25     5      > FE_RESET_R                                       $6      !1, ->11
          6    > > FE_FETCH_R                                               $6, !2, ->11
   26     7    >   INIT_FCALL                                               'var_dump'
          8        SEND_VAR                                                 !2
          9        DO_ICALL                                                 
   25    10      > JMP                                                      ->6
         11    >   FE_FREE                                                  $6
   27    12      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
239.7 ms | 999 KiB | 15 Q