3v4l.org

run code in 300+ PHP versions simultaneously
<?php $info = finfo_open(FILEINFO_MIME_TYPE); if (!$info) die('no finfo available'); $buffer = <<<JSON {asd:'asd'} JSON ; $result = finfo_buffer($info, $buffer); finfo_close($info); if ($result === false) { die('Failed to read file'); } var_dump($result);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 18, Position 2 = 19
Branch analysis from position: 18
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/iteti
function name:  (null)
number of ops:  23
compiled vars:  !0 = $info, !1 = $buffer, !2 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'finfo_open'
          1        SEND_VAL                                                 16
          2        DO_ICALL                                         $3      
          3        ASSIGN                                                   !0, $3
    4     4        BOOL_NOT                                         ~5      !0
          5      > JMPZ                                                     ~5, ->7
          6    > > EXIT                                                     'no+finfo+available'
    5     7    >   ASSIGN                                                   !1, '%7Basd%3A%27asd%27%7D'
    9     8        INIT_FCALL                                               'finfo_buffer'
          9        SEND_VAR                                                 !0
         10        SEND_VAR                                                 !1
         11        DO_ICALL                                         $7      
         12        ASSIGN                                                   !2, $7
   10    13        INIT_FCALL                                               'finfo_close'
         14        SEND_VAR                                                 !0
         15        DO_ICALL                                                 
   12    16        TYPE_CHECK                                    4          !2
         17      > JMPZ                                                     ~10, ->19
   13    18    > > EXIT                                                     'Failed+to+read+file'
   16    19    >   INIT_FCALL                                               'var_dump'
         20        SEND_VAR                                                 !2
         21        DO_ICALL                                                 
         22      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
178.61 ms | 1387 KiB | 21 Q