3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = '20160530105130'; $dt = DateTime::createFromFormat('!Ym????????',$str); var_dump($dt); //object(DateTime)#2 (3) { ["date"]=> string(26) "2016-05-01 00:00:00.000000"
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/bOJdU
function name:  (null)
number of ops:  10
compiled vars:  !0 = $str, !1 = $dt
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '20160530105130'
    5     1        INIT_STATIC_METHOD_CALL                                  'DateTime', 'createFromFormat'
          2        SEND_VAL                                                 '%21Ym%3F%3F%3F%3F%3F%3F%3F%3F'
          3        SEND_VAR                                                 !0
          4        DO_FCALL                                      0  $3      
          5        ASSIGN                                                   !1, $3
    7     6        INIT_FCALL                                               'var_dump'
          7        SEND_VAR                                                 !1
          8        DO_ICALL                                                 
    8     9      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
233.21 ms | 1008 KiB | 14 Q