3v4l.org

run code in 300+ PHP versions simultaneously
<?php $xmlBuilder = new \SimpleXMLElement('<response></response>'); $xmlBuilder->addChild('result', '5'); $xmlBuilder->addChild('comment', 'Some natural comment'); echo $xmlBuilder->asXML();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uHFtk
function name:  (null)
number of ops:  16
compiled vars:  !0 = $xmlBuilder
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   NEW                                              $1      'SimpleXMLElement'
          1        SEND_VAL_EX                                              '%3Cresponse%3E%3C%2Fresponse%3E'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $1
    3     4        INIT_METHOD_CALL                                         !0, 'addChild'
          5        SEND_VAL_EX                                              'result'
          6        SEND_VAL_EX                                              '5'
          7        DO_FCALL                                      0          
    4     8        INIT_METHOD_CALL                                         !0, 'addChild'
          9        SEND_VAL_EX                                              'comment'
         10        SEND_VAL_EX                                              'Some+natural+comment'
         11        DO_FCALL                                      0          
    5    12        INIT_METHOD_CALL                                         !0, 'asXML'
         13        DO_FCALL                                      0  $6      
         14        ECHO                                                     $6
         15      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.97 ms | 1393 KiB | 13 Q