3v4l.org

run code in 300+ PHP versions simultaneously
<?php $time = new DateTime(); Locale::setDefault('en_GB'); echo IntlDateFormatter::formatObject($time)."\n"; echo IntlDateFormatter::formatObject($time, [IntlDateFormatter::NONE, IntlDateFormatter::MEDIUM])."\n"; echo IntlDateFormatter::formatObject($time, [IntlDateFormatter::MEDIUM, IntlDateFormatter::NONE])."\n";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/9I2Av
function name:  (null)
number of ops:  32
compiled vars:  !0 = $time
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $1      'DateTime'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
    4     3        INIT_STATIC_METHOD_CALL                                  'Locale', 'setDefault'
          4        SEND_VAL_EX                                              'en_GB'
          5        DO_FCALL                                      0          
    5     6        INIT_STATIC_METHOD_CALL                                  'IntlDateFormatter', 'formatObject'
          7        SEND_VAR_EX                                              !0
          8        DO_FCALL                                      0  $5      
          9        CONCAT                                           ~6      $5, '%0A'
         10        ECHO                                                     ~6
    6    11        INIT_STATIC_METHOD_CALL                                  'IntlDateFormatter', 'formatObject'
         12        SEND_VAR_EX                                              !0
         13        FETCH_CLASS_CONSTANT                             ~7      'IntlDateFormatter', 'NONE'
         14        INIT_ARRAY                                       ~8      ~7
         15        FETCH_CLASS_CONSTANT                             ~9      'IntlDateFormatter', 'MEDIUM'
         16        ADD_ARRAY_ELEMENT                                ~8      ~9
         17        SEND_VAL_EX                                              ~8
         18        DO_FCALL                                      0  $10     
         19        CONCAT                                           ~11     $10, '%0A'
         20        ECHO                                                     ~11
    7    21        INIT_STATIC_METHOD_CALL                                  'IntlDateFormatter', 'formatObject'
         22        SEND_VAR_EX                                              !0
         23        FETCH_CLASS_CONSTANT                             ~12     'IntlDateFormatter', 'MEDIUM'
         24        INIT_ARRAY                                       ~13     ~12
         25        FETCH_CLASS_CONSTANT                             ~14     'IntlDateFormatter', 'NONE'
         26        ADD_ARRAY_ELEMENT                                ~13     ~14
         27        SEND_VAL_EX                                              ~13
         28        DO_FCALL                                      0  $15     
         29        CONCAT                                           ~16     $15, '%0A'
         30        ECHO                                                     ~16
         31      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
157.81 ms | 1395 KiB | 13 Q