3v4l.org

run code in 300+ PHP versions simultaneously
<?php $intlDateFormatter = new IntlDateFormatter( 'en_US', IntlDateFormatter::MEDIUM, IntlDateFormatter::NONE, 'Asia/Nicosia', IntlDateFormatter::GREGORIAN, 'yyyy-MM-dd' ); $intlDateFormatter->setLenient(false); $date = '1990-03-24'; $res = $intlDateFormatter->parse($date); echo "$date - $res\n"; // 1990-03-24 - 638229600 $date = '1990-03-25'; $res = $intlDateFormatter->parse($date, $pos); var_dump($res); var_dump($pos); echo "$date - $res\n"; // 1990-03-25 - $date = '1990-03-26'; $res = $intlDateFormatter->parse($date); echo "$date - $res\n"; // 1990-03-26 - 638398800
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/OfNY2
function name:  (null)
number of ops:  53
compiled vars:  !0 = $intlDateFormatter, !1 = $date, !2 = $res, !3 = $pos
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $4      'IntlDateFormatter'
    4     1        SEND_VAL_EX                                              'en_US'
    5     2        FETCH_CLASS_CONSTANT                             ~5      'IntlDateFormatter', 'MEDIUM'
          3        SEND_VAL_EX                                              ~5
    6     4        FETCH_CLASS_CONSTANT                             ~6      'IntlDateFormatter', 'NONE'
          5        SEND_VAL_EX                                              ~6
    7     6        SEND_VAL_EX                                              'Asia%2FNicosia'
    8     7        FETCH_CLASS_CONSTANT                             ~7      'IntlDateFormatter', 'GREGORIAN'
          8        SEND_VAL_EX                                              ~7
    9     9        SEND_VAL_EX                                              'yyyy-MM-dd'
         10        DO_FCALL                                      0          
    3    11        ASSIGN                                                   !0, $4
   11    12        INIT_METHOD_CALL                                         !0, 'setLenient'
         13        SEND_VAL_EX                                              <false>
         14        DO_FCALL                                      0          
   13    15        ASSIGN                                                   !1, '1990-03-24'
   14    16        INIT_METHOD_CALL                                         !0, 'parse'
         17        SEND_VAR_EX                                              !1
         18        DO_FCALL                                      0  $12     
         19        ASSIGN                                                   !2, $12
   16    20        ROPE_INIT                                     4  ~15     !1
         21        ROPE_ADD                                      1  ~15     ~15, '+-+'
         22        ROPE_ADD                                      2  ~15     ~15, !2
         23        ROPE_END                                      3  ~14     ~15, '%0A'
         24        ECHO                                                     ~14
   18    25        ASSIGN                                                   !1, '1990-03-25'
   19    26        INIT_METHOD_CALL                                         !0, 'parse'
         27        SEND_VAR_EX                                              !1
         28        SEND_VAR_EX                                              !3
         29        DO_FCALL                                      0  $18     
         30        ASSIGN                                                   !2, $18
   20    31        INIT_FCALL                                               'var_dump'
         32        SEND_VAR                                                 !2
         33        DO_ICALL                                                 
   21    34        INIT_FCALL                                               'var_dump'
         35        SEND_VAR                                                 !3
         36        DO_ICALL                                                 
   22    37        ROPE_INIT                                     4  ~23     !1
         38        ROPE_ADD                                      1  ~23     ~23, '+-+'
         39        ROPE_ADD                                      2  ~23     ~23, !2
         40        ROPE_END                                      3  ~22     ~23, '%0A'
         41        ECHO                                                     ~22
   24    42        ASSIGN                                                   !1, '1990-03-26'
   25    43        INIT_METHOD_CALL                                         !0, 'parse'
         44        SEND_VAR_EX                                              !1
         45        DO_FCALL                                      0  $26     
         46        ASSIGN                                                   !2, $26
   26    47        ROPE_INIT                                     4  ~29     !1
         48        ROPE_ADD                                      1  ~29     ~29, '+-+'
         49        ROPE_ADD                                      2  ~29     ~29, !2
         50        ROPE_END                                      3  ~28     ~29, '%0A'
         51        ECHO                                                     ~28
         52      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
161.2 ms | 1400 KiB | 15 Q