3v4l.org

run code in 500+ PHP versions simultaneously
<?php $str = '東舘町'; var_dump(mb_detect_encoding($str, ['UTF-8', 'SJIS-WIN'])); var_dump(mb_detect_encoding($str, ['UTF-8', 'SJIS-WIN'], true)); var_dump(mb_detect_encoding($str, ['UTF-8', 'SJIS-WIN'], false));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/686vj
function name:  (null)
number of ops:  25
compiled vars:  !0 = $str
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, '%E6%9D%B1%E8%88%98%E7%94%BA'
    4     1        INIT_FCALL                                                   'var_dump'
          2        INIT_FCALL                                                   'mb_detect_encoding'
          3        SEND_VAR                                                     !0
          4        SEND_VAL                                                     <array>
          5        DO_ICALL                                             $2      
          6        SEND_VAR                                                     $2
          7        DO_ICALL                                                     
    5     8        INIT_FCALL                                                   'var_dump'
          9        INIT_FCALL                                                   'mb_detect_encoding'
         10        SEND_VAR                                                     !0
         11        SEND_VAL                                                     <array>
         12        SEND_VAL                                                     <true>
         13        DO_ICALL                                             $4      
         14        SEND_VAR                                                     $4
         15        DO_ICALL                                                     
    6    16        INIT_FCALL                                                   'var_dump'
         17        INIT_FCALL                                                   'mb_detect_encoding'
         18        SEND_VAR                                                     !0
         19        SEND_VAL                                                     <array>
         20        SEND_VAL                                                     <false>
         21        DO_ICALL                                             $6      
         22        SEND_VAR                                                     $6
         23        DO_ICALL                                                     
         24      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
183.07 ms | 1722 KiB | 15 Q