3v4l.org

run code in 500+ PHP versions simultaneously
<?php ini_set('error_reporting',PHP_INT_MAX-1); $xml=<<<EOF <?xml version="1.0"?> <test/> EOF; $xsd=<<<EOF <?xml version="1.0"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> <xs:include schemaLocation="nonexistent.xsd"/> <xs:element name="test"/> </xs:schema> EOF; libxml_set_external_entity_loader(function($p,$s,$c) { var_dump($p,$s,$c); die(); }); $dom=new DOMDocument($xml); var_dump($dom->schemaValidateSource($xsd));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/9endu
function name:  (null)
number of ops:  21
compiled vars:  !0 = $xml, !1 = $xsd, !2 = $dom
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                                   'ini_set'
          1        SEND_VAL                                                     'error_reporting'
          2        SEND_VAL                                                     9223372036854775806
          3        DO_ICALL                                                     
    3     4        ASSIGN                                                       !0, '%3C%3Fxml+version%3D%221.0%22%3F%3E%0A%3Ctest%2F%3E'
    8     5        ASSIGN                                                       !1, '%3C%3Fxml+version%3D%221.0%22%3F%3E%0A%3Cxs%3Aschema+xmlns%3Axs%3D%22http%3A%2F%2Fwww.w3.org%2F2001%2FXMLSchema%22%3E%0A++%3Cxs%3Ainclude+schemaLocation%3D%22nonexistent.xsd%22%2F%3E%0A++%3Cxs%3Aelement+name%3D%22test%22%2F%3E%0A%3C%2Fxs%3Aschema%3E'
   16     6        INIT_FCALL                                                   'libxml_set_external_entity_loader'
          7        DECLARE_LAMBDA_FUNCTION                              ~6      [0]
   19     8        SEND_VAL                                                     ~6
   16     9        DO_ICALL                                                     
   21    10        NEW                                                  $8      'DOMDocument'
         11        SEND_VAR_EX                                                  !0
         12        DO_FCALL                                          0          
         13        ASSIGN                                                       !2, $8
   22    14        INIT_FCALL                                                   'var_dump'
         15        INIT_METHOD_CALL                                             !2, 'schemaValidateSource'
         16        SEND_VAR_EX                                                  !1
         17        DO_FCALL                                          0  $11     
         18        SEND_VAR                                                     $11
         19        DO_ICALL                                                     
         20      > RETURN                                                       1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 61) Position 1 = -2
filename:       /in/9endu
function name:  {closure:/in/9endu:16}
number of ops:  11
compiled vars:  !0 = $p, !1 = $s, !2 = $c
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   16     0  E >   RECV                                                 !0      
          1        RECV                                                 !1      
          2        RECV                                                 !2      
   17     3        INIT_FCALL                                                   'var_dump'
          4        SEND_VAR                                                     !0
          5        SEND_VAR                                                     !1
          6        SEND_VAR                                                     !2
          7        DO_ICALL                                                     
   18     8      > INIT_FCALL                                                   'exit'
          9*       DO_ICALL                                                     
   19    10*     > RETURN                                                       null

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
176.11 ms | 2639 KiB | 17 Q